80 Commits

Author SHA1 Message Date
746ae2a09f „.drone.yml“ ändern
All checks were successful
continuous-integration/drone/push Build is passing
2019-09-19 13:55:39 +00:00
b93485e087 „.drone.yml“ ändern
Some checks failed
continuous-integration/drone/push Build is failing
2019-09-19 13:54:35 +00:00
88d29263de „.drone.yml“ ändern
Some checks failed
continuous-integration/drone/push Build encountered an error
2019-09-19 13:54:04 +00:00
ac86fa6ccb „.drone.yml“ ändern
Some checks failed
continuous-integration/drone/push Build is failing
2019-09-19 13:25:49 +00:00
f5a656911e „.drone.yml“ hinzufügen
Some checks failed
continuous-integration/drone/push Build encountered an error
2019-09-19 13:24:27 +00:00
László Monda
310b00319a Update MCUXpresso IDE to version 11.0.1_2563 2019-09-08 14:40:55 +02:00
László Monda
0bf3456292 Tweak changelog. 2019-08-30 13:48:07 +02:00
László Monda
2ab727b423 Bump version to 8.6.0, update changelog and versions.h 2019-08-23 20:39:48 +02:00
László Monda
ecdcfea8a4 Merge pull request #239 from UltimateHackingKeyboard/chore-refactor-release-script
chore: refactor the make-release.js file
2019-08-23 19:31:15 +02:00
László Monda
f73d3a1c22 Merge pull request #240 from UltimateHackingKeyboard/chore-sign-cla
Sign CLA
2019-08-23 19:29:29 +02:00
Róbert Kiss
53a1065219 Sign CLA
I have read the Agreement, and fully agree to it by signing it with my GitHub username.
2019-08-23 19:24:49 +02:00
Róbert Kiss
2b8156cad8 chore: refactor the make-release.js file 2019-08-23 19:22:10 +02:00
László Monda
c564d04b22 Add SerializedMouseAction_Button_[78] and set SerializedMouseAction_Last to SerializedMouseAction_Button_8 2019-08-22 23:08:54 +02:00
László Monda
65e1e5e25a Merge pull request #238 from stephengroat/patch-1
stephengroat sign cla
2019-08-09 12:55:06 +02:00
Stephen
0a28a395fc stephengroat sign cla 2019-08-08 23:51:38 -07:00
László Monda
08e567797e Reorder signatures alphabetically. 2019-07-21 23:36:34 +02:00
László Monda
0e53bee212 Merge pull request #236 from eltang/sign-cla
Sign CLA
2019-07-21 23:08:13 +02:00
Eric Tang
d8d8a543c0 Sign CLA 2019-07-21 15:54:11 -05:00
László Monda
97cff6438e Merge pull request #232 from Lauszus/patch-1
Sign CLA
2019-07-02 02:43:59 +02:00
Kristian Sloth Lauszus
7755c57478 Sign CLA 2019-07-01 19:38:53 +02:00
László Monda
8aea024ed2 Merge pull request #226 from santiagogf89/patch-1
Sign CLA
2019-06-24 19:29:02 +02:00
Santiago
e5a7ded3d1 Sign CLA
I have read the Agreement, and fully agree to it by signing it with my GitHub username.
2019-06-24 17:58:27 +02:00
László Monda
d9d8a91817 Scroll instead of moving the pointer with the blackberry trackball. 2019-06-13 14:54:41 +02:00
László Monda
262eb4a695 Fix blackberry trackball directions. 2019-06-13 14:44:13 +02:00
László Monda
b4cd3fab9b Rename BLACKBERRY_TRACKBALL_{TOP,BOTTOM} to BLACKBERRY_TRACKBALL_{UP,DOWN} 2019-06-13 14:37:14 +02:00
László Monda
3e87ed851a Make the blackberry trackball pointer move in all 4 directions. 2019-06-13 14:26:19 +02:00
László Monda
60dade7e18 Make the BlackBerry trackball work in one direction. 2019-06-12 01:44:27 +02:00
László Monda
6c0ebc3223 Merge branch 'master' of github.com:UltimateHackingKeyboard/firmware 2019-06-11 22:00:27 +02:00
László Monda
a857780e42 Add pointer_delta_t and make the master and slaves handle it. 2019-06-11 21:58:40 +02:00
Erich Styger
6e77dece04 singed CLA 2019-06-11 12:47:20 +02:00
László Monda
a57fedec70 Use UhkModuleSlaveDriver_DriverIdToSlotId() in UhkModuleSlaveDriver_Update() 2019-06-11 00:46:47 +02:00
László Monda
95003cf55d Reimplement SLOT_ID_TO_UHK_MODULE_DRIVER_ID as UhkModuleSlaveDriver_SlotIdToDriverId and UHK_MODULE_DRIVER_ID_TO_SLOT_ID as UhkModuleSlaveDriver_DriverIdToSlotId 2019-06-11 00:42:32 +02:00
László Monda
4486f607da Make condition slightly more readable. 2019-06-11 00:28:21 +02:00
László Monda
0caf0144dc Rename UhkModuleDriverId_{Left,Right}Addon to UhkModuleDriverId_{Left,Right}Module 2019-06-10 23:02:12 +02:00
László Monda
3686b2a6ff Fix installation instructions regarding the GNU ARM Eclipse Plugins 2019-06-09 22:55:53 +02:00
László Monda
bf286b944e Merge pull request #225 from xdever/cla
Sign CLA
2019-06-09 20:27:29 +02:00
Róbert Csordás
19cdca27e7 CLA 2019-06-09 12:58:42 +02:00
László Monda
657f998afa Merge pull request #224 from kareltucek/cla
Sign CLA
2019-06-08 20:45:42 +02:00
Karel Tuček
d6d5178d87 sign cla 2019-06-08 17:50:08 +02:00
László Monda
06d1643b4f Merge pull request #223 from UltimateHackingKeyboard/sign-cla
Sign CLA
2019-06-07 21:49:50 +02:00
László Monda
3058438d88 Sign CLA. 2019-06-07 21:48:14 +02:00
László Monda
10150c4eca Update CONTRIBUTING.md 2019-06-07 21:46:44 +02:00
László Monda
196dfe3d15 Add CLA. 2019-06-07 21:26:32 +02:00
László Monda
d08de0e31d Include module.h instead of modules.h 2019-05-22 22:13:19 +02:00
László Monda
e948af3df4 Rename I2C_ADDRESS_*_ADDON_* defines to I2C_ADDRESS_*_MODULE_* 2019-05-21 23:05:10 +02:00
László Monda
fc300fff0c Add I2C_ADDRESS_MODULE_BOOTLOADER 2019-05-16 00:22:51 +02:00
László Monda
16c5cac395 Add I2C_ADDRESS_MODULE_FIRMWARE. 2019-05-16 00:18:51 +02:00
László Monda
e2e14ac73b Change the I2C address of the key cluster to I2C_ADDRESS_LEFT_MODULE_BOOTLOADER 2019-05-16 00:00:11 +02:00
László Monda
cfb15b6902 Rename *_ADDON_* I2C addresses to *_MODULE_* 2019-05-15 23:59:04 +02:00
László Monda
92752a5963 Reference the latest Agent. 2019-05-15 23:50:12 +02:00
László Monda
6b74a01a0b Change module id to ModuleId_KeyClusterLeft, MODULE_POINTER_COUNT to 1 and the keyboard matrix size to 2x2. 2019-05-15 23:19:14 +02:00
László Monda
b92bf86b99 Add firmware for the key cluster module based on the firmware of the left keyboard half. 2019-05-15 22:58:05 +02:00
László Monda
8f98bf3d2f Merge pull request #217 from kareltucek/empty_macro_fix
Fix play of empty macro
2019-04-01 13:14:50 +02:00
Karel Tuček
a712ac6c8a Fix play of empty macro 2019-04-01 12:51:59 +02:00
László Monda
f54967ddab Merge pull request #215 from kareltucek/type_fix
fix wrong type
2019-04-01 02:19:45 +02:00
Karel Tuček
4832384cf3 fix key->mouseButton 2019-03-31 22:21:47 +02:00
Karel Tuček
f310e26c8e fix wrong type 2019-03-31 21:35:26 +02:00
László Monda
afb434a4bd Try to fix chatter by maintaining the strobe between the invocations of KeyMatrix_ScanRow() 2019-03-29 09:26:37 +01:00
László Monda
ff14aa8842 Merge pull request #210 from p4elkin/canonical-readme-update
add https://github.com/p4elkin/firmware to the list of featured forks
2019-03-06 10:33:51 +01:00
Aleksandr Pchelintcev
0ed9c62602 add https://github.com/p4elkin/firmware to the list of featured forks 2019-03-06 09:17:37 +02:00
László Monda
1373380221 Update README.md 2019-02-09 18:43:25 +01:00
László Monda
3f8314474a Update README.md 2019-02-09 18:40:58 +01:00
László Monda
da5e668ad2 Link the latest 10.3.0 MCUXpresso IDE versions. 2019-02-09 04:34:59 +01:00
László Monda
5e382c67e9 Update README.md 2019-02-08 07:04:51 +01:00
László Monda
9076a3a6c0 Blink the right test LED at the same 100ms interval as the left test LED. 2019-02-07 00:27:43 +01:00
László Monda
6ab0c2eb72 Bump version to 8.5.4, update changelog, package.json and versions.h 2019-01-05 16:16:37 +01:00
László Monda
2e73bb9ea1 Merge pull request #203 from UltimateHackingKeyboard/sticky-modifiers
Adjust the behavior of sticky modifiers
2018-12-26 03:42:47 +01:00
Eric Tang
e5ac605b4c Adjust the behavior of sticky modiifers 2018-12-25 16:08:10 -08:00
László Monda
fb220038b7 Merge pull request #200 from kareltucek/origin_master
Feature firmware forks in readme
2018-11-18 14:44:46 +01:00
Karel Tuček
464c56f599 Feature firmware forks in Readme 2018-11-18 12:36:34 +01:00
László Monda
a59b43b433 Bump version to 8.5.3, update package.json, changelog, versions.h and reference the latest Agent. 2018-10-20 01:20:31 +02:00
László Monda
ceb2f3de00 Re-enable the I2C watchdog of the left keyboard half which was accidentally disabled starting from firmware 8.4.3. This should fix the freezes of the left keyboard half. 2018-10-20 01:11:36 +02:00
László Monda
5cd4030a93 Merge branch 'master' of github.com:UltimateHackingKeyboard/firmware 2018-10-06 21:33:16 +02:00
László Monda
21ae72dd9e Bump version to 8.5.2, update changelog, package.json, versions.h, and Agent. 2018-10-06 21:31:32 +02:00
László Monda
dba61c6a42 Merge pull request #186 from UltimateHackingKeyboard/action-cache
Extend the behavior of keys upon layer changes to keymap changes
2018-10-06 20:56:06 +02:00
László Monda
f61acc483b Update ISSUE_TEMPLATE 2018-10-06 20:26:47 +02:00
László Monda
fb38e4099b Update ISSUE_TEMPLATE 2018-10-06 20:03:51 +02:00
László Monda
5fe19abe06 Merge branch 'master' into action-cache 2018-10-06 19:44:08 +02:00
Eric Tang
06e34fdcbc Convert the layer cache to an action cache 2018-10-06 10:02:46 -05:00
Eric Tang
cc6666b96d Don't suppress keys upon keymap changes 2018-10-06 10:02:23 -05:00
60 changed files with 1777 additions and 128 deletions

25
.drone.yml Normal file
View File

@@ -0,0 +1,25 @@
kind: pipeline
type: docker
name: default
steps:
- name: submodules
image: docker:git
commands:
- git submodule update --recursive --init
- name: build left, debug
image: hardwario/gcc-arm-embedded:7-2017-q4-major
commands:
- make -j2 -C left DEBUG=1
- name: build left
image: hardwario/gcc-arm-embedded:7-2017-q4-major
commands:
- make -j2 -C left DEBUG=0
- name: build right, debug
image: hardwario/gcc-arm-embedded:7-2017-q4-major
commands:
- make -j2 -C right DEBUG=1
- name: build right
image: hardwario/gcc-arm-embedded:7-2017-q4-major
commands:
- make -j2 -C right DEBUG=0

View File

@@ -5,6 +5,32 @@ All notable changes to this project will be documented in this file.
The format is loosely based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to the [UHK Versioning](VERSIONING.md) conventions.
## [8.6.0] - 2018-08-23
Device Protocol: 4.5.0 | Module Protocol: 4.**1.0** | User Config: 4.1.**1** | Hardware Config: 1.0.0
- Make the config parser accept mouse button 4 to 8. `USERCONFIG:PATCH`
- Implement API for modules to send pointer movements to the master. `MODULEPROTOCOL:MINOR`
- Fix empty macro playback.
## [8.5.4] - 2018-01-05
Device Protocol: 4.5.0 | Module Protocol: 4.0.0 | User Config: 4.1.0 | Hardware Config: 1.0.0
- Make the modifiers of shortcut keys stick only as long as the layer switcher key of a shortcut key is being held.
## [8.5.3] - 2018-10-20
Device Protocol: 4.5.0 | Module Protocol: 4.0.0 | User Config: 4.1.0 | Hardware Config: 1.0.0
- Re-enable the I2C watchdog of the left keyboard half which was accidentally disabled starting from firmware 8.4.3. This should fix the freezes of the left keyboard half.
## [8.5.2] - 2018-10-06
Device Protocol: 4.5.0 | Module Protocol: 4.0.0 | User Config: 4.1.0 | Hardware Config: 1.0.0
- Don't suppress keys upon keymap change.
## [8.5.1] - 2018-10-04
Device Protocol: 4.5.0 | Module Protocol: 4.0.0 | User Config: 4.1.0 | Hardware Config: 1.0.0

View File

@@ -1,3 +1,17 @@
# Signing the CLA
Before contributing to this project, you must sign [the CLA](/cla/cla-1.0.0.md).
To sign the CLA, add your GitHub username to the end of the CLA. Make sure that the usernames remain alphabetically sorted.
Then create a pull request with the title:
> Sign CLA
and with the body:
> I have read the Agreement, and fully agree to it by signing it with my GitHub username.
# Coding standards
## Literal structure

View File

@@ -1 +1,8 @@
If you're using Karabiner Elements on your Mac, then stop here! Make sure to close Karabiner Elements, then try to reproduce the issue again, even if you think that Karabiner Elements shouldn't be the cause. Karabiner Elements is the source of numerous problems, and we don't want to receive any more reports it causes.
Before submitting a new issue, make sure to do the following:
1. If you're using Karabiner Elements on your Mac, close it!
2. Install the latest Agent:
https://github.com/UltimateHackingKeyboard/agent/releases/latest
3. Use Agent to update to the latest firmware:
https://github.com/UltimateHackingKeyboard/firmware/releases/latest
4. Try to reproduce the issue, and only report it if it still persists.

View File

@@ -12,16 +12,33 @@ If you're one of the brave few who wants to hack the firmware then read on.
`git clone --recursive git@github.com:UltimateHackingKeyboard/firmware.git`
2. Download and install MCUXpresso IDE for [Linux](https://storage.googleapis.com/ugl-static/mcuxpresso-ide/mcuxpressoide-10.2.1_795.x86_64.deb.bin), [Mac](https://storage.googleapis.com/ugl-static/mcuxpresso-ide/MCUXpressoIDE_10.2.1_795.pkg), or [Windows](https://storage.googleapis.com/ugl-static/mcuxpresso-ide/MCUXpressoIDE_10.2.1_795.exe).
2. Download and install MCUXpresso IDE for [Linux](https://storage.googleapis.com/ugl-static/mcuxpresso-ide/mcuxpressoide-11.0.1_2563.x86_64.deb.bin), [Mac](https://storage.googleapis.com/ugl-static/mcuxpresso-ide/MCUXpressoIDE_11.0.1_2563.pkg), or [Windows](https://storage.googleapis.com/ugl-static/mcuxpresso-ide/MCUXpressoIDE_11.0.1_2563.exe).
3. In the IDE, import the project by invoking *File -> Import -> General -> Existing Projects into Workspace*, select the *left* or *right* directory depending on the desired firmware, then click on the *Finish* button.
3. Install the GNU ARM Eclipse Plugins for in McuXpresso IDE. This is needed to make indexing work, and to avoid the "Orphaned configuration" error message in project properties.
1. Visit the [latest release](https://github.com/gnu-mcu-eclipse/eclipse-plugins/releases/latest).
2. Download the zip file.
3. In MCUXpresso IDE, go to Help > "Install New Software...", then a new dialog will appear.
4. Click the "Add..." button, then a new dialog will appear.
5. Click the "Archive..." button and choose the downloaded zip file.
6. Go with the flow and install the plugin.
4. In order to be able to flash the firmware via USB from the IDE, you must build [Agent](https://github.com/UltimateHackingKeyboard/agent) which is Git submodule of the this repo and located in the `lib/agent` directory.
4. In the IDE, import this project by invoking *File -> Import -> General -> Existing Projects into Workspace*, select the *left* or *right* directory depending on the desired firmware, then click on the *Finish* button.
5. Finally, in the IDE, click on *Run -> External Tools -> External Tools Configurations*, then select a release firmware to be flashed such as *uhk60-right_release_kboot*, and click on the *Run* button.
5. In order to be able to flash the firmware via USB from the IDE, you must build [Agent](https://github.com/UltimateHackingKeyboard/agent) which is Git submodule of the this repo and located in the `lib/agent` directory.
6. Finally, in the IDE, click on *Run -> External Tools -> External Tools Configurations*, then select a release firmware to be flashed such as *uhk60-right_release_kboot*, and click on the *Run* button.
Going forward, it's easier to flash the firmware of your choice by using the downwards toolbar icon which is located rightwards of the *green play + toolbox icon*.
## Contributing
Want to contribute? Let us show you [how](/CONTRIBUTING.md).
## Custom Firmwares
The following list contains unofficial forks of the firmware. These forks provide functionality unavailable in the official firmware, but come without guarantees of any kind:
- [https://github.com/kareltucek/firmware](https://github.com/kareltucek/firmware) - firmware featuring macro engine extended by a set of custom commands, allowing more advanced configurations including custom layer switching logic, doubletap bindings, alternative secondary roles etc.
- [https://github.com/p4elkin/firmware](https://github.com/p4elkin/firmware) - firmware fork which comes with an alternative implementation of the secondary key role mechanism making it possible to use the feature for keys actively involved in typing (e.g. alphanumeric ones).

108
cla/cla-1.0.0.md Normal file
View File

@@ -0,0 +1,108 @@
# Contributor Agreement
## Individual Contributor Exclusive License Agreement version 1.0.0
Thank you for your interest in contributing to Ultimate Gadget Laboratories Kft.'s Ultimate Hacking Keyboard firmware ("We" or "Us").
The purpose of this contributor agreement ("Agreement") is to clarify and document the rights granted by contributors to Us.
By signing this Agreement, you agree that the following terms apply to all of your past, present and future contributions to the project.
## How to use this Contributor Agreement
If You are an employee and have created the Contribution as part of your employment, You need to have Your employer approve this Agreement or sign the Entity version of this document. If You do not own the Copyright in the entire work of authorship, any other author of the Contribution should also sign this in any event, please contact Us at support@UltimateHackingKeyboard.com
## 1. Definitions
**"You"** means the individual Copyright owner who Submits a Contribution to Us.
**"Contribution"** means any original work of authorship, including any original modifications or additions to an existing work of authorship, Submitted by You to Us, in which You own the Copyright.
**"Copyright"** means all rights protecting works of authorship, including copyright, moral and neighboring rights, as appropriate, for the full term of their existence.
**"Material"** means the software or documentation made available by Us to third parties. When this Agreement covers more than one software project, the Material means the software or documentation to which the Contribution was Submitted. After You Submit the Contribution, it may be included in the Material.
**"Submit"** means any act by which a Contribution is transferred to Us by You by means of tangible or intangible media, including but not limited to electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, Us, but excluding any transfer that is conspicuously marked or otherwise designated in writing by You as "Not a Contribution."
**"Documentation"** means any non-software portion of a Contribution.
## 2. License grant
### 2.1 Copyright license to Us
Subject to the terms and conditions of this Agreement, You hereby grant to Us a worldwide, royalty-free, exclusive, perpetual and irrevocable (except as stated in Section 8.2) license, with the right to transfer an unlimited number of non-exclusive licenses or to grant sublicenses to third parties, under the Copyright covering the Contribution to use the Contribution by all means, including, but not limited to:
* publish the Contribution,
* modify the Contribution,
* prepare derivative works based upon or containing the Contribution and/or to combine the Contribution with other Materials,
* reproduce the Contribution in original or modified form,
* distribute, to make the Contribution available to the public, display and publicly perform the Contribution in original or modified form.
### 2.2 Moral rights
Moral Rights remain unaffected to the extent they are recognized and not waivable by applicable law.
### 2.3 Copyright license back to You
Upon such grant of rights to Us, We immediately grant to You a worldwide, royalty-free, non-exclusive, perpetual and irrevocable license, with the right to transfer an unlimited number of non-exclusive licenses or to grant sublicenses to third parties, under the Copyright covering the Contribution to use the Contribution by all means, including, but not limited to:
* publish the Contribution,
* modify the Contribution,
* prepare derivative works based upon or containing the Contribution and/or to combine the Contribution with other Materials,
* reproduce the Contribution in original or modified form,
* distribute, to make the Contribution available to the public, display and publicly perform the Contribution in original or modified form.
This license back is limited to the Contribution and does not provide any rights to the Material.
## 3. Patents
### 3.1 Patent license
Subject to the terms and conditions of this Agreement You hereby grant to Us and to recipients of Materials distributed by Us a worldwide, royalty-free, non-exclusive, perpetual and irrevocable (except as stated in Section 3.2) patent license, with the right to transfer an unlimited number of non-exclusive licenses or to grant sublicenses to third parties, to make, have made, use, sell, offer for sale, import and otherwise transfer the Contribution and the Contribution in combination with any Material (and portions of such combination). This license applies to all patents owned or controlled by You, whether already acquired or hereafter acquired, that would be infringed by making, having made, using, selling, offering for sale, importing or otherwise transferring of Your Contribution(s) alone or by combination of Your Contribution(s) with any Material.
### 3.2 Revocation of patent license
You reserve the right to revoke the patent license stated in section 3.1 if We make any infringement claim that is targeted at your Contribution and not asserted for a Defensive Purpose. An assertion of claims of the Patents shall be considered for a "Defensive Purpose" if the claims are asserted against an entity that has filed, maintained, threatened, or voluntarily participated in a patent infringement lawsuit against Us or any of Our licensees.
## 4. Disclaimer
THE CONTRIBUTION IS PROVIDED "AS IS". MORE PARTICULARLY, ALL EXPRESS OR IMPLIED WARRANTIES INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTY OF SATISFACTORY QUALITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE EXPRESSLY DISCLAIMED BY YOU TO US AND BY US TO YOU. TO THE EXTENT THAT ANY SUCH WARRANTIES CANNOT BE DISCLAIMED, SUCH WARRANTY IS LIMITED IN DURATION AND EXTENT TO THE MINIMUM PERIOD AND EXTENT PERMITTED BY LAW.
## 5. Consequential damage waiver
TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, IN NO EVENT WILL YOU OR WE BE LIABLE FOR ANY LOSS OF PROFITS, LOSS OF ANTICIPATED SAVINGS, LOSS OF DATA, INDIRECT, SPECIAL, INCIDENTAL, CONSEQUENTIAL AND EXEMPLARY DAMAGES ARISING OUT OF THIS AGREEMENT REGARDLESS OF THE LEGAL OR EQUITABLE THEORY (CONTRACT, TORT OR OTHERWISE) UPON WHICH THE CLAIM IS BASED.
## 6. Approximation of disclaimer and damage waiver
IF THE DISCLAIMER AND DAMAGE WAIVER MENTIONED IN SECTION 4. AND SECTION 5. CANNOT BE GIVEN LEGAL EFFECT UNDER APPLICABLE LOCAL LAW, REVIEWING COURTS SHALL APPLY LOCAL LAW THAT MOST CLOSELY APPROXIMATES AN ABSOLUTE WAIVER OF ALL CIVIL OR CONTRACTUAL LIABILITY IN CONNECTION WITH THE CONTRIBUTION.
## 7. Term
7.1 This Agreement shall come into effect upon Your acceptance of the terms and conditions.
7.2 In the event of a termination of this Agreement Sections 4, 5, 6, 7 and 8 shall survive such termination and shall remain in full force thereafter. For the avoidance of doubt, (sub)licenses that have already been granted for Contributions at the date of the termination shall remain in full force after the termination of this Agreement.
## 8. Miscellaneous
8.1 This Agreement and all disputes, claims, actions, suits or other proceedings arising out of this agreement or relating in any way to it shall be governed by the laws of Hungary excluding its private international law provisions.
8.2 This Agreement sets out the entire agreement between You and Us for Your Contributions to Us and overrides all other agreements or understandings.
8.3 In case of Your death, this agreement shall continue with Your heirs. In case of more than one heir, all heirs must exercise their rights through a commonly authorized person.
8.4 If any provision of this Agreement is found void and unenforceable, such provision will be replaced to the extent possible with a provision that comes closest to the meaning of the original provision and that is enforceable. The terms and conditions set forth in this Agreement shall apply notwithstanding any failure of essential purpose of this Agreement or any limited remedy to the maximum extent possible under law.
8.5 You agree to notify Us of any facts or circumstances of which you become aware that would make this Agreement inaccurate in any respect.
## 9. Signatures
I have read this Agreement, and fully agree to it by signing it with my GitHub username:
- @eltang
- @kareltucek
- @Lauszus
- @mondalaci
- @santiagogf89
- @tastyger
- @xdever
- @stephengroat
- @ert78gb

58
keycluster/Makefile Normal file
View File

@@ -0,0 +1,58 @@
# Copyright (C) 2018 Kristian Lauszus. All rights reserved.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# Contact information
# -------------------
# Kristian Lauszus
# Web : http://www.lauszus.com
# e-mail : lauszus@gmail.com
# Set project name.
PROJECT_NAME = uhk_keycluster
# Defines the part type that this project uses.
PART = MKL03Z32VFK4
# Defines the linker script to use for the application.
LDSCRIPT = ../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/gcc/MKL03Z32xxx4_flash.ld
# Size of the heap and stack.
HEAP_SIZE = 0
STACK_SIZE = 0x0050
# Set the compiler CPU and FPU options.
CPU = -mcpu=cortex-m0plus
FPU = -mfloat-abi=soft
# Command for flashing the key cluster module.
FLASH_CMD = node ../lib/agent/packages/usb/update-module-firmware.js leftModule $(PROJECT_OBJ:.axf=.bin)
# Path to the JLink script used for the key cluster module.
JLINK_SCRIPT = ../scripts/flash-keycluster.jlink
# Source files.
SOURCE = $(wildcard src/*.c) \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/system_MKL03Z4.c \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/gcc/startup_MKL03Z4.S \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_clock.c \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_gpio.c \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_i2c.c \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_lptmr.c \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_spi.c \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_tpm.c \
$(wildcard ../shared/*.c) \
$(wildcard ../shared/slave/*.c)
# Header files.
IPATH = src \
../lib/KSDK_2.0_MKL03Z8xxx4/CMSIS/Include \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4 \
../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers \
../shared
# Include main Makefile.
include ../scripts/Makedefs.mk

3
keycluster/README.md Normal file
View File

@@ -0,0 +1,3 @@
# Key cluster module firmware
This directory contains the firmware of the key cluster module.

350
keycluster/build/.cproject Normal file
View File

@@ -0,0 +1,350 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
<storageModule moduleId="org.eclipse.cdt.core.settings">
<cconfiguration id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861" moduleId="org.eclipse.cdt.core.settings" name="uhk60-keycluster_debug">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe,org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.debug" cleanCommand="${cross_rm} -rf" description="" id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861" name="uhk60-keycluster_debug" parent="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug">
<folderInfo id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861." name="/" resourcePath="">
<toolChain id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.elf.debug.439601044" name="Cross ARM GCC" superClass="ilg.gnuarmeclipse.managedbuild.cross.toolchain.elf.debug">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level.780228407" name="Optimization Level" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level" value="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level.most" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.messagelength.1547417078" name="Message length (-fmessage-length=0)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.messagelength" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.signedchar.765602671" name="'char' is signed (-fsigned-char)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.signedchar" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.functionsections.910567930" name="Function sections (-ffunction-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.functionsections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.datasections.243581182" name="Data sections (-fdata-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.datasections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.allwarn.416266830" name="Enable all common warnings (-Wall)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.allwarn" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level.1613409592" name="Debug level" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level" value="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level.default" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format.556186202" name="Debug format" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format" value="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format.default" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.name.873832382" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.name" value="Custom" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.architecture.1923839154" name="Architecture" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.architecture" value="ilg.gnuarmeclipse.managedbuild.cross.option.architecture.arm" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.family.292907889" name="ARM family" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.family" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.mcpu.cortex-m0plus" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset.1510156849" name="Instruction set" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset.thumb" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.prefix.1110645397" name="Prefix" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.prefix" value="arm-none-eabi-" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.c.1996567256" name="C compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.c" value="gcc" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.cpp.2014665560" name="C++ compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.cpp" value="g++" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.objcopy.867581768" name="Hex/Bin converter" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.objcopy" value="objcopy" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.objdump.315789427" name="Listing generator" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.objdump" value="objdump" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.size.348642956" name="Size command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.size" value="size" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.make.670689833" name="Build command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.make" value="make" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.rm.654501139" name="Remove command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.rm" value="rm" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createflash.967248865" name="Create flash image" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createflash" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.printsize.1390211406" name="Print size" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.printsize" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.useglobalpath.228343129" name="Use global path" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.useglobalpath" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.unit.1173170148" name="FPU Type" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.unit" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.unit.default" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi.1949324826" name="Float ABI" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi.soft" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.ar.1370140886" name="Archiver" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.ar" value="ar" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nocommon.9959419695" name="No common unitialized (-fno-common)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nocommon" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.freestanding.2882966171" name="Assume freestanding environment (-ffreestanding)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.freestanding" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nobuiltin.9288453635" name="Disable builtin (-fno-builtin)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nobuiltin" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.lto.2986114257" name="Link-time optimizer (-flto)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.lto" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.nowarn.7864424720" name="Inhibit all warnings (-w)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.nowarn" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.extrawarn.6408004182" name="Enable extra warnings (-Wextra)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.extrawarn" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.conversion.8753144693" name="Warn on implicit conversions (-Wconversion)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.conversion" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pointerarith.7561379406" name="Warn if pointer arithmetic (-Wpointer-arith)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pointerarith" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.shadow.5875269774" name="Warn if shadowed variable (-Wshadow)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.shadow" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.logicalop.8232620757" name="Warn if suspicious logical ops (-Wlogical-op)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.logicalop" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.agreggatereturn.5398426966" name="Warn if struct is returned (-Wagreggate-return)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.agreggatereturn" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.floatequal.4503086702" name="Warn if floats are compared as equal (-Wfloat-equal)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.floatequal" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.toerrors.4431038008" name="Generate errors instead of warnings (-Werror)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.toerrors" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.unitialized.8290768044" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.unitialized" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.missingdeclaration.378454944" name="Warn on undeclared global function (-Wmissing-declaration)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.missingdeclaration" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.badfunctioncast.2943267007" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.badfunctioncast" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createlisting.9995899345" name="Create extended listing" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createlisting" value="false" valueType="boolean"/>
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="ilg.gnuarmeclipse.managedbuild.cross.targetPlatform.1777290613" isAbstract="false" osList="all" superClass="ilg.gnuarmeclipse.managedbuild.cross.targetPlatform"/>
<builder buildPath="${workspace_loc:/uhk-keycluster}/../" id="ilg.gnuarmeclipse.managedbuild.cross.builder.1406291427" incrementalBuildTarget="all DEBUG=1" keepEnvironmentInBuildfile="false" managedBuildOn="false" name="Gnu Make Builder" parallelBuildOn="true" parallelizationNumber="optimal" stopOnErr="false" superClass="ilg.gnuarmeclipse.managedbuild.cross.builder"/>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.2007968129" name="Cross ARM GNU Assembler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.usepreprocessor.1246588554" name="Use preprocessor" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.usepreprocessor" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.include.paths.2122094274" name="Include paths (-I)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.include.paths"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.defs.1822362302" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.defs" valueType="definedSymbols">
<listOptionValue builtIn="false" value="DEBUG"/>
<listOptionValue builtIn="false" value="__STARTUP_CLEAR_BSS"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.nostdinc.8788969731" name="Do not search system directories (-nostdinc)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.nostdinc" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.other.1923601167" name="Other assembler flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.other" value=" -mapcs " valueType="string"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.input.2014783385" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.input"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.1397207158" name="Cross ARM C Compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.paths.336878990" name="Include paths (-I)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.paths" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/CMSIS/Include"/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices"/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers"/>
<listOptionValue builtIn="false" value=".."/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/utilities"/>
<listOptionValue builtIn="false" value="../../.."/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4"/>
<listOptionValue builtIn="false" value="../../../shared"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.std.933718024" name="Language standard" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.std" useByScannerDiscovery="true" value="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.std.gnu99" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.7934865376" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="DEBUG"/>
<listOptionValue builtIn="false" value="CPU_MKL03Z32VFK4"/>
<listOptionValue builtIn="false" value="PRINTF_FLOAT_ENABLE=0"/>
<listOptionValue builtIn="false" value="SCANF_FLOAT_ENABLE=0"/>
<listOptionValue builtIn="false" value="PRINTF_ADVANCED_ENABLE=0"/>
<listOptionValue builtIn="false" value="SCANF_ADVANCED_ENABLE=0"/>
<listOptionValue builtIn="false" value="FRDM_KL03Z"/>
<listOptionValue builtIn="false" value="FREEDOM"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.nostdinc.1704317783" name="Do not search system directories (-nostdinc)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.nostdinc" useByScannerDiscovery="true" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.1560348183" name="Other compiler flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other" useByScannerDiscovery="true" value=" -mapcs " valueType="string"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input.1895544709" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.435207489" name="Cross ARM C++ Compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.defs.2050754817" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.defs" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="UHK_PCB_MAJOR_VERSION=7"/>
</option>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input.1699166727" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker.1681324840" name="Cross ARM C Linker" outputPrefix="" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.gcsections.1850945755" name="Remove unused sections (-Xlinker --gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.gcsections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.usenewlibnano.1816597929" name="Use newlib-nano (--specs=nano.specs)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.usenewlibnano" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.scriptfile.1573832003" name="Script files (-T)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.scriptfile"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.libs.2061142742" name="Libraries (-l)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.libs"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker.input.1168552163" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool commandLinePattern="${COMMAND} ${cross_toolchain_flags} ${FLAGS} ${OUTPUT_FLAG} ${OUTPUT_PREFIX}${OUTPUT} -Xlinker --start-group ${INPUTS} -Xlinker --end-group" id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.1475612095" name="Cross ARM C++ Linker" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.gcsections.42905068" name="Remove unused sections (-Xlinker --gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.gcsections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.usenewlibnano.1816597929" name="Use newlib-nano (--specs=nano.specs)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.usenewlibnano" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.otherobjs.6905766738" name="Other objects" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.otherobjs"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.scriptfile.4021849263" name="Script files (-T)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.scriptfile" valueType="stringList">
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/gcc/MKL03Z32xxx4_flash.ld"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nostart.6846138787" name="Do not use standard start files (-nostartfiles)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nostart" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nodeflibs.8043932112" name="Do not use default libraries (-nodefaultlibs)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nodeflibs" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.libs.2257416827" name="Libraries (-l)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.libs" valueType="libs">
<listOptionValue builtIn="false" value="m"/>
<listOptionValue builtIn="false" value="g"/>
<listOptionValue builtIn="false" value="gcc"/>
<listOptionValue builtIn="false" value="nosys"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.cref.6563555683" name="Cross reference (-Xlinker --cref)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.cref" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.printgcsections.8052175158" name="Print removed sections (-Xlinker --print-gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.printgcsections" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.strip.4023108413" name="Omit all symbol information (-s)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.strip" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.other.255052480" name="Other linker flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.other" value="-mapcs -Xlinker -static -Xlinker -z -Xlinker muldefs -Xlinker -defsym=__heap_size__=0" valueType="string"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.input.658447495" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.archiver.717958418" name="Cross ARM GNU Archiver" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.archiver"/>
<tool command="${cross_prefix}${cross_objcopy}${cross_suffix}" commandLinePattern="${COMMAND} ${FLAGS} ${OUTPUT_FLAG} ${OUTPUT_PREFIX}${OUTPUT}" id="ilg.gnuarmeclipse.managedbuild.cross.tool.createflash.1498748442" name="Cross ARM GNU Create Flash Image" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.createflash">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createflash.choice.396105459" name="Output file format (-O)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createflash.choice" value="ilg.gnuarmeclipse.managedbuild.cross.option.createflash.choice.binary" valueType="enumerated"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.createlisting.1921141825" name="Cross ARM GNU Create Listing" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.createlisting">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.source.1147761851" name="Display source (--source|-S)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.source" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.allheaders.326654770" name="Display all headers (--all-headers|-x)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.allheaders" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.demangle.2012585764" name="Demangle names (--demangle|-C)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.demangle" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.linenumbers.1639985926" name="Display line numbers (--line-numbers|-l)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.linenumbers" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.wide.795915960" name="Wide lines (--wide|-w)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.wide" value="true" valueType="boolean"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.printsize.204256629" name="Cross ARM GNU Print Size" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.printsize">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.printsize.format.48990078" name="Size format" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.printsize.format"/>
</tool>
</toolChain>
</folderInfo>
<fileInfo id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861.1146590441" name="fsl_clock.h" rcbsApplicability="disable" resourcePath="drivers/fsl_clock.h" toolsToInvoke=""/>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
<storageModule moduleId="ilg.gnuarmeclipse.managedbuild.packs"/>
</cconfiguration>
<cconfiguration id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834.1792647078">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834.1792647078" moduleId="org.eclipse.cdt.core.settings" name="uhk60-keycluster_release">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe,org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.release" cleanCommand="${cross_rm} -rf" description="" id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834.1792647078" name="uhk60-keycluster_release" parent="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release">
<folderInfo id="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834.1792647078." name="/" resourcePath="">
<toolChain id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.elf.release.1802192936" name="Cross ARM GCC" superClass="ilg.gnuarmeclipse.managedbuild.cross.toolchain.elf.release">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level.918206081" name="Optimization Level" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level" value="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level.size" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.messagelength.1247972134" name="Message length (-fmessage-length=0)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.messagelength" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.signedchar.1651670889" name="'char' is signed (-fsigned-char)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.signedchar" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.functionsections.1807399992" name="Function sections (-ffunction-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.functionsections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.datasections.1522408084" name="Data sections (-fdata-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.datasections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.allwarn.881879429" name="Enable all common warnings (-Wall)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.allwarn" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level.417088354" name="Debug level" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level" value="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level.none" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format.471396471" name="Debug format" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format" value="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format.default" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.name.378484607" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.name" value="Custom" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.architecture.1093394082" name="Architecture" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.architecture" value="ilg.gnuarmeclipse.managedbuild.cross.option.architecture.arm" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.family.1818095636" name="ARM family" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.family" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.mcpu.cortex-m0plus" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset.336711378" name="Instruction set" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset.thumb" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.prefix.1351526286" name="Prefix" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.prefix" value="arm-none-eabi-" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.c.1438555896" name="C compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.c" value="gcc" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.cpp.1588534593" name="C++ compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.cpp" value="g++" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.objcopy.1663641144" name="Hex/Bin converter" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.objcopy" value="objcopy" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.objdump.200920623" name="Listing generator" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.objdump" value="objdump" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.size.362080964" name="Size command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.size" value="size" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.make.2009924231" name="Build command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.make" value="make" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.rm.1536468905" name="Remove command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.rm" value="rm" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createflash.925865305" name="Create flash image" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createflash" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.printsize.1208668505" name="Print size" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.printsize" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.useglobalpath.1166058417" name="Use global path" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.useglobalpath" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.ar.1139561820" name="Archiver" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.ar" value="ar" valueType="string"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi.671070963" name="Float ABI" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi.soft" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nocommon.1275482104" name="No common unitialized (-fno-common)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nocommon" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.freestanding.407638415" name="Assume freestanding environment (-ffreestanding)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.freestanding" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nobuiltin.1259530104" name="Disable builtin (-fno-builtin)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nobuiltin" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.lto.809059548" name="Link-time optimizer (-flto)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.lto" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.nowarn.1208094284" name="Inhibit all warnings (-w)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.nowarn" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.extrawarn.67984531" name="Enable extra warnings (-Wextra)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.extrawarn" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.conversion.593444999" name="Warn on implicit conversions (-Wconversion)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.conversion" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pointerarith.813635782" name="Warn if pointer arithmetic (-Wpointer-arith)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pointerarith" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.shadow.1455227593" name="Warn if shadowed variable (-Wshadow)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.shadow" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.logicalop.1717005013" name="Warn if suspicious logical ops (-Wlogical-op)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.logicalop" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.agreggatereturn.383697767" name="Warn if struct is returned (-Wagreggate-return)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.agreggatereturn" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.floatequal.628316174" name="Warn if floats are compared as equal (-Wfloat-equal)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.floatequal" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.toerrors.1624700406" name="Generate errors instead of warnings (-Werror)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.toerrors" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.unitialized.3064955983.625210850" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.unitialized" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.missingdeclaration.907753672" name="Warn on undeclared global function (-Wmissing-declaration)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.missingdeclaration" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.badfunctioncast.6545741443.1540890614" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.badfunctioncast" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createlisting.1382191896" name="Create extended listing" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createlisting" value="false" valueType="boolean"/>
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="ilg.gnuarmeclipse.managedbuild.cross.targetPlatform.2107171855" isAbstract="false" osList="all" superClass="ilg.gnuarmeclipse.managedbuild.cross.targetPlatform"/>
<builder buildPath="${workspace_loc:/uhk-keycluster}/../" id="ilg.gnuarmeclipse.managedbuild.cross.builder.1689719605" incrementalBuildTarget="all DEBUG=0" keepEnvironmentInBuildfile="false" managedBuildOn="false" name="Gnu Make Builder" parallelBuildOn="true" parallelizationNumber="optimal" stopOnErr="false" superClass="ilg.gnuarmeclipse.managedbuild.cross.builder"/>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.1477971290" name="Cross ARM GNU Assembler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.usepreprocessor.334227408" name="Use preprocessor" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.usepreprocessor" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.include.paths.1702866230" name="Include paths (-I)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.include.paths"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.defs.1072633432" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.defs" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__STARTUP_CLEAR_BSS"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.nostdinc.415052570" name="Do not search system directories (-nostdinc)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.nostdinc" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.other.1359123195" name="Other assembler flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.other" value=" -mapcs " valueType="string"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.input.1499693341" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.input"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.1046326518" name="Cross ARM C Compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.paths.746372967" name="Include paths (-I)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.paths" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/CMSIS/Include"/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices"/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers"/>
<listOptionValue builtIn="false" value=".."/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/utilities"/>
<listOptionValue builtIn="false" value="../../.."/>
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4"/>
<listOptionValue builtIn="false" value="../../../shared"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.std.1703504273" name="Language standard" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.std" useByScannerDiscovery="true" value="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.std.gnu99" valueType="enumerated"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.220715196" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="NDEBUG"/>
<listOptionValue builtIn="false" value="CPU_MKL03Z32VFK4"/>
<listOptionValue builtIn="false" value="PRINTF_FLOAT_ENABLE=0"/>
<listOptionValue builtIn="false" value="SCANF_FLOAT_ENABLE=0"/>
<listOptionValue builtIn="false" value="PRINTF_ADVANCED_ENABLE=0"/>
<listOptionValue builtIn="false" value="SCANF_ADVANCED_ENABLE=0"/>
<listOptionValue builtIn="false" value="FRDM_KL03Z"/>
<listOptionValue builtIn="false" value="FREEDOMx"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.nostdinc.1784976960" name="Do not search system directories (-nostdinc)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.nostdinc" useByScannerDiscovery="true" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.182809566" name="Other compiler flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other" useByScannerDiscovery="true" value=" -mapcs " valueType="string"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input.2141870622" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.1055651769" name="Cross ARM C++ Compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.defs.1344565144" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.defs" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="UHK_PCB_MAJOR_VERSION=7"/>
</option>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input.1785701410" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker.1248876094" name="Cross ARM C Linker" outputPrefix="" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.gcsections.205211813" name="Remove unused sections (-Xlinker --gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.gcsections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.usenewlibnano.764117584" name="Use newlib-nano (--specs=nano.specs)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.usenewlibnano" value="true" valueType="boolean"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker.input.424272008" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool commandLinePattern="${COMMAND} ${cross_toolchain_flags} ${FLAGS} ${OUTPUT_FLAG} ${OUTPUT_PREFIX}${OUTPUT} -Xlinker --start-group ${INPUTS} -Xlinker --end-group" id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.20615499" name="Cross ARM C++ Linker" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.gcsections.1664132146" name="Remove unused sections (-Xlinker --gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.gcsections" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.usenewlibnano.1704968656" name="Use newlib-nano (--specs=nano.specs)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.usenewlibnano" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.otherobjs.359701763" name="Other objects" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.otherobjs"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.scriptfile.51816293" name="Script files (-T)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.scriptfile" valueType="stringList">
<listOptionValue builtIn="false" value="../../../lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/gcc/MKL03Z32xxx4_flash.ld"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nostart.554768103" name="Do not use standard start files (-nostartfiles)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nostart" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nodeflibs.1987989417" name="Do not use default libraries (-nodefaultlibs)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.nodeflibs" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.libs.1653206096" name="Libraries (-l)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.libs" valueType="libs">
<listOptionValue builtIn="false" value="m"/>
<listOptionValue builtIn="false" value="g"/>
<listOptionValue builtIn="false" value="gcc"/>
<listOptionValue builtIn="false" value="nosys"/>
</option>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.cref.1514842438" name="Cross reference (-Xlinker --cref)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.cref" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.printgcsections.1127263805" name="Print removed sections (-Xlinker --print-gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.printgcsections" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.strip.549891305" name="Omit all symbol information (-s)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.strip" value="false" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.other.1551896832" name="Other linker flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.other" value="-mapcs -Xlinker -static -Xlinker -z -Xlinker muldefs" valueType="string"/>
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.input.772761405" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.archiver.1579053840" name="Cross ARM GNU Archiver" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.archiver"/>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.createflash.1400319152" name="Cross ARM GNU Create Flash Image" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.createflash">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createflash.choice.1328839591" name="Output file format (-O)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createflash.choice" value="ilg.gnuarmeclipse.managedbuild.cross.option.createflash.choice.binary" valueType="enumerated"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.createlisting.733953661" name="Cross ARM GNU Create Listing" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.createlisting">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.source.1802395103" name="Display source (--source|-S)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.source" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.allheaders.1353511477" name="Display all headers (--all-headers|-x)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.allheaders" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.demangle.562396163" name="Demangle names (--demangle|-C)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.demangle" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.linenumbers.1889527374" name="Display line numbers (--line-numbers|-l)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.linenumbers" value="true" valueType="boolean"/>
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.wide.2076712477" name="Wide lines (--wide|-w)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.wide" value="true" valueType="boolean"/>
</tool>
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.printsize.843351449" name="Cross ARM GNU Print Size" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.printsize">
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.printsize.format.1881713953" name="Size format" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.printsize.format"/>
</tool>
</toolChain>
</folderInfo>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
<storageModule moduleId="ilg.gnuarmeclipse.managedbuild.packs"/>
</cconfiguration>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<project id="k64f.ilg.gnuarmeclipse.managedbuild.cross.target.elf.1537007018" name="Executable" projectType="ilg.gnuarmeclipse.managedbuild.cross.target.elf"/>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders">
</storageModule>
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"/>
<storageModule moduleId="scannerConfiguration">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861;ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861.;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.435207489;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input.1699166727">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834;ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834.;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.955273220;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input.1711058916">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834;ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834.;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.270191615;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input.1469754472">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861;ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861.;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.1397207158;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input.1895544709">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
<storageModule moduleId="refreshScope" versionNumber="2">
<configuration configurationName="uhk60-keycluster_release">
<resource resourceType="PROJECT" workspacePath="/uhk-keycluster"/>
</configuration>
<configuration configurationName="uhk60-keycluster_debug">
<resource resourceType="PROJECT" workspacePath="/uhk-keycluster"/>
</configuration>
</storageModule>
</cproject>

4
keycluster/build/.gitignore vendored Normal file
View File

@@ -0,0 +1,4 @@
/.settings/
/uhk60-keycluster_debug/
/uhk60-keycluster_release/
/uhk60-keycluster_release/

155
keycluster/build/.project Normal file
View File

@@ -0,0 +1,155 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>uhk-keycluster</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>com.freescale.processorexpert.core.expertprojectbuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
<triggers>clean,full,incremental,</triggers>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
<triggers>full,incremental,</triggers>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>com.freescale.processorexpert.core.expertprojectnature</nature>
<nature>org.eclipse.cdt.core.cnature</nature>
<nature>org.eclipse.cdt.core.ccnature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
</natures>
<linkedResources>
<link>
<name>Makedefs.mk</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/scripts/Makedefs.mk</locationURI>
</link>
<link>
<name>Makefile</name>
<type>1</type>
<locationURI>PARENT-1-PROJECT_LOC/Makefile</locationURI>
</link>
<link>
<name>drivers</name>
<type>2</type>
<locationURI>virtual:/virtual</locationURI>
</link>
<link>
<name>shared</name>
<type>2</type>
<locationURI>PARENT-2-PROJECT_LOC/shared</locationURI>
</link>
<link>
<name>src</name>
<type>2</type>
<locationURI>PARENT-1-PROJECT_LOC/src</locationURI>
</link>
<link>
<name>startup</name>
<type>2</type>
<locationURI>virtual:/virtual</locationURI>
</link>
<link>
<name>drivers/fsl_clock.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_clock.c</locationURI>
</link>
<link>
<name>drivers/fsl_clock.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_clock.h</locationURI>
</link>
<link>
<name>drivers/fsl_gpio.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_gpio.c</locationURI>
</link>
<link>
<name>drivers/fsl_gpio.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_gpio.h</locationURI>
</link>
<link>
<name>drivers/fsl_i2c.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_i2c.c</locationURI>
</link>
<link>
<name>drivers/fsl_i2c.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_i2c.h</locationURI>
</link>
<link>
<name>drivers/fsl_lptmr.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_lptmr.c</locationURI>
</link>
<link>
<name>drivers/fsl_lptmr.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_lptmr.h</locationURI>
</link>
<link>
<name>drivers/fsl_port.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_port.h</locationURI>
</link>
<link>
<name>drivers/fsl_smc.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_smc.c</locationURI>
</link>
<link>
<name>drivers/fsl_smc.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_smc.h</locationURI>
</link>
<link>
<name>drivers/fsl_spi.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_spi.c</locationURI>
</link>
<link>
<name>drivers/fsl_spi.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_spi.h</locationURI>
</link>
<link>
<name>drivers/fsl_tpm.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_tpm.c</locationURI>
</link>
<link>
<name>drivers/fsl_tpm.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/drivers/fsl_tpm.h</locationURI>
</link>
<link>
<name>startup/startup_MKL03Z4.S</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/gcc/startup_MKL03Z4.S</locationURI>
</link>
<link>
<name>startup/system_MKL03Z4.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/system_MKL03Z4.c</locationURI>
</link>
<link>
<name>startup/system_MKL03Z4.h</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/lib/KSDK_2.0_MKL03Z8xxx4/devices/MKL03Z4/system_MKL03Z4.h</locationURI>
</link>
</linkedResources>
</projectDescription>

View File

@@ -0,0 +1,82 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="ilg.gnuarmeclipse.debug.gdbjtag.jlink.launchConfigurationType">
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doConnectToRunning" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doContinue" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doDebugInRam" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doFirstReset" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerAllocateConsole" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerAllocateSemihostingConsole" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerInitRegs" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerLocalOnly" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerSilent" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerVerifyDownload" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doSecondReset" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doStartGdbServer" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableFlashBreakpoints" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSemihosting" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSemihostingIoclientGdbClient" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSemihostingIoclientTelnet" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSwo" value="false"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.firstResetSpeed" value="30"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.firstResetType" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbClientOtherCommands" value="set mem inaccessible-by-default off"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbClientOtherOptions" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerConnection" value="usb"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerConnectionAddress" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDebugInterface" value="swd"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDeviceEndianness" value="little"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDeviceName" value="MKL03Z32xxx4"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDeviceSpeed" value="30"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerExecutable" value="${jlink_path}/${jlink_gdbserver}"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerGdbPortNumber" value="2331"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerLog" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerOther" value="-s"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerSwoPortNumber" value="2332"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerTelnetPortNumber" value="2333"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.interfaceSpeed" value="auto"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.otherInitCommands" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.otherRunCommands" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.secondResetType" value=""/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.swoEnableTargetCpuFreq" value="0"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.swoEnableTargetPortMask" value="0x1"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.swoEnableTargetSwoFreq" value="0"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageOffset" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.ipAddress" value="localhost"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.jtagDevice" value="GNU ARM J-Link"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadImage" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadSymbols" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.pcRegister" value=""/>
<intAttribute key="org.eclipse.cdt.debug.gdbjtag.core.portNumber" value="2331"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setPcRegister" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setResume" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setStopAt" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.stopAt" value="main"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsOffset" value=""/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForImage" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForSymbols" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForImage" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForSymbols" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useRemoteTarget" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.commandFactory" value="Standard (Windows)"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.protocol" value="mi"/>
<booleanAttribute key="org.eclipse.cdt.debug.mi.core.verboseMode" value="false"/>
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="${cross_prefix}gdb${cross_suffix}"/>
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.UPDATE_THREADLIST_ON_SUSPEND" value="false"/>
<intAttribute key="org.eclipse.cdt.launch.ATTR_BUILD_BEFORE_LAUNCH_ATTR" value="2"/>
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="uhk60-keycluster_debug/uhk-keycluster.elf"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="uhk-keycluster"/>
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="false"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_ID_ATTR" value="ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.1792027861"/>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
<listEntry value="/uhk-keycluster"/>
</listAttribute>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
<listEntry value="4"/>
</listAttribute>
<stringAttribute key="org.eclipse.dsf.launch.MEMORY_BLOCKS" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;memoryBlockExpressionList context=&quot;Context string&quot;/&gt;&#13;&#10;"/>
<stringAttribute key="process_factory_id" value="org.eclipse.cdt.dsf.gdb.GdbProcessFactory"/>
</launchConfiguration>

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.ui.externaltools.ProgramLaunchConfigurationType">
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE" value="${none}"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="/usr/bin/make"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS" value="-j8 DEBUG=1 flash"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_WORKING_DIRECTORY" value="${workspace_loc:/uhk-keycluster}/../"/>
</launchConfiguration>

View File

@@ -0,0 +1,82 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="ilg.gnuarmeclipse.debug.gdbjtag.jlink.launchConfigurationType">
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doConnectToRunning" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doContinue" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doDebugInRam" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doFirstReset" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerAllocateConsole" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerAllocateSemihostingConsole" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerInitRegs" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerLocalOnly" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerSilent" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doGdbServerVerifyDownload" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doSecondReset" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.doStartGdbServer" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableFlashBreakpoints" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSemihosting" value="true"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSemihostingIoclientGdbClient" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSemihostingIoclientTelnet" value="false"/>
<booleanAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.enableSwo" value="true"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.firstResetSpeed" value="30"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.firstResetType" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbClientOtherCommands" value="set mem inaccessible-by-default off"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbClientOtherOptions" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerConnection" value="usb"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerConnectionAddress" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDebugInterface" value="swd"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDeviceEndianness" value="little"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDeviceName" value="MKL03Z32xxx4"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerDeviceSpeed" value="30"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerExecutable" value="${jlink_path}/${jlink_gdbserver}"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerGdbPortNumber" value="2331"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerLog" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerOther" value="-s"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerSwoPortNumber" value="2332"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.gdbServerTelnetPortNumber" value="2333"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.interfaceSpeed" value="auto"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.otherInitCommands" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.otherRunCommands" value=""/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.secondResetType" value=""/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.swoEnableTargetCpuFreq" value="0"/>
<stringAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.swoEnableTargetPortMask" value="0x1"/>
<intAttribute key="ilg.gnuarmeclipse.debug.gdbjtag.jlink.swoEnableTargetSwoFreq" value="0"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageOffset" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.ipAddress" value="localhost"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.jtagDevice" value="GNU ARM J-Link"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadImage" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadSymbols" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.pcRegister" value=""/>
<intAttribute key="org.eclipse.cdt.debug.gdbjtag.core.portNumber" value="2331"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setPcRegister" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setResume" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setStopAt" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.stopAt" value="main"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsOffset" value=""/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForImage" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForSymbols" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForImage" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForSymbols" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useRemoteTarget" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.commandFactory" value="Standard (Windows)"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.protocol" value="mi"/>
<booleanAttribute key="org.eclipse.cdt.debug.mi.core.verboseMode" value="false"/>
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="${cross_prefix}gdb${cross_suffix}"/>
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.UPDATE_THREADLIST_ON_SUSPEND" value="false"/>
<intAttribute key="org.eclipse.cdt.launch.ATTR_BUILD_BEFORE_LAUNCH_ATTR" value="2"/>
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="uhk60-keycluster_release/uhk-keycluster.elf"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="uhk-keycluster"/>
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="false"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_ID_ATTR" value="ilg.gnuarmeclipse.managedbuild.cross.config.elf.release.1939339834.1792647078"/>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
<listEntry value="/uhk-keycluster"/>
</listAttribute>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
<listEntry value="4"/>
</listAttribute>
<stringAttribute key="org.eclipse.dsf.launch.MEMORY_BLOCKS" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;memoryBlockExpressionList context=&quot;Context string&quot;/&gt;&#13;&#10;"/>
<stringAttribute key="process_factory_id" value="org.eclipse.cdt.dsf.gdb.GdbProcessFactory"/>
</launchConfiguration>

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.ui.externaltools.ProgramLaunchConfigurationType">
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE" value="${none}"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="/usr/bin/make"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS" value="-j8 DEBUG=0 flash"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_WORKING_DIRECTORY" value="${workspace_loc:/uhk-keycluster}/../"/>
</launchConfiguration>

View File

@@ -0,0 +1,61 @@
#include "fsl_gpio.h"
#include "fsl_port.h"
#include "blackberry_trackball.h"
pointer_delta_t BlackBerryTrackball_PointerDelta;
void BlackberryTrackball_Init(void)
{
CLOCK_EnableClock(BLACKBERRY_TRACKBALL_LEFT_CLOCK);
PORT_SetPinMux(BLACKBERRY_TRACKBALL_LEFT_PORT, BLACKBERRY_TRACKBALL_LEFT_PIN, kPORT_MuxAsGpio);
PORT_SetPinInterruptConfig(BLACKBERRY_TRACKBALL_LEFT_PORT, BLACKBERRY_TRACKBALL_LEFT_PIN, kPORT_InterruptEitherEdge);
NVIC_EnableIRQ(BLACKBERRY_TRACKBALL_LEFT_IRQ);
CLOCK_EnableClock(BLACKBERRY_TRACKBALL_RIGHT_CLOCK);
PORT_SetPinMux(BLACKBERRY_TRACKBALL_RIGHT_PORT, BLACKBERRY_TRACKBALL_RIGHT_PIN, kPORT_MuxAsGpio);
PORT_SetPinInterruptConfig(BLACKBERRY_TRACKBALL_RIGHT_PORT, BLACKBERRY_TRACKBALL_RIGHT_PIN, kPORT_InterruptEitherEdge);
NVIC_EnableIRQ(BLACKBERRY_TRACKBALL_RIGHT_IRQ);
CLOCK_EnableClock(BLACKBERRY_TRACKBALL_UP_CLOCK);
PORT_SetPinMux(BLACKBERRY_TRACKBALL_UP_PORT, BLACKBERRY_TRACKBALL_UP_PIN, kPORT_MuxAsGpio);
PORT_SetPinInterruptConfig(BLACKBERRY_TRACKBALL_UP_PORT, BLACKBERRY_TRACKBALL_UP_PIN, kPORT_InterruptEitherEdge);
NVIC_EnableIRQ(BLACKBERRY_TRACKBALL_UP_IRQ);
CLOCK_EnableClock(BLACKBERRY_TRACKBALL_DOWN_CLOCK);
PORT_SetPinMux(BLACKBERRY_TRACKBALL_DOWN_PORT, BLACKBERRY_TRACKBALL_DOWN_PIN, kPORT_MuxAsGpio);
PORT_SetPinInterruptConfig(BLACKBERRY_TRACKBALL_DOWN_PORT, BLACKBERRY_TRACKBALL_DOWN_PIN, kPORT_InterruptEitherEdge);
NVIC_EnableIRQ(BLACKBERRY_TRACKBALL_DOWN_IRQ);
}
void handleTrackball(void)
{
if (PORT_GetPinsInterruptFlags(BLACKBERRY_TRACKBALL_LEFT_PORT) & (1 << BLACKBERRY_TRACKBALL_LEFT_PIN)) {
BlackBerryTrackball_PointerDelta.x++;
GPIO_ClearPinsInterruptFlags(BLACKBERRY_TRACKBALL_LEFT_GPIO, 1U << BLACKBERRY_TRACKBALL_LEFT_PIN);
}
if (PORT_GetPinsInterruptFlags(BLACKBERRY_TRACKBALL_RIGHT_PORT) & (1 << BLACKBERRY_TRACKBALL_RIGHT_PIN)) {
BlackBerryTrackball_PointerDelta.x--;
GPIO_ClearPinsInterruptFlags(BLACKBERRY_TRACKBALL_RIGHT_GPIO, 1U << BLACKBERRY_TRACKBALL_RIGHT_PIN);
}
if (PORT_GetPinsInterruptFlags(BLACKBERRY_TRACKBALL_UP_PORT) & (1 << BLACKBERRY_TRACKBALL_UP_PIN)) {
BlackBerryTrackball_PointerDelta.y++;
GPIO_ClearPinsInterruptFlags(BLACKBERRY_TRACKBALL_UP_GPIO, 1U << BLACKBERRY_TRACKBALL_UP_PIN);
}
if (PORT_GetPinsInterruptFlags(BLACKBERRY_TRACKBALL_DOWN_PORT) & (1 << BLACKBERRY_TRACKBALL_DOWN_PIN)) {
BlackBerryTrackball_PointerDelta.y--;
GPIO_ClearPinsInterruptFlags(BLACKBERRY_TRACKBALL_DOWN_GPIO, 1U << BLACKBERRY_TRACKBALL_DOWN_PIN);
}
}
void BLACKBERRY_TRACKBALL_IRQ_HANDLER1(void)
{
handleTrackball();
}
void BLACKBERRY_TRACKBALL_IRQ_HANDLER2(void)
{
handleTrackball();
}

View File

@@ -0,0 +1,45 @@
#ifndef __BLACKBERRY_TRACKBALL_H__
#define __BLACKBERRY_TRACKBALL_H__
// Includes:
#include "slave_protocol.h"
// Macros:
#define BLACKBERRY_TRACKBALL_LEFT_PORT PORTB
#define BLACKBERRY_TRACKBALL_LEFT_GPIO GPIOB
#define BLACKBERRY_TRACKBALL_LEFT_IRQ PORTB_IRQn
#define BLACKBERRY_TRACKBALL_LEFT_CLOCK kCLOCK_PortB
#define BLACKBERRY_TRACKBALL_LEFT_PIN 0
#define BLACKBERRY_TRACKBALL_RIGHT_PORT PORTB
#define BLACKBERRY_TRACKBALL_RIGHT_GPIO GPIOB
#define BLACKBERRY_TRACKBALL_RIGHT_IRQ PORTB_IRQn
#define BLACKBERRY_TRACKBALL_RIGHT_CLOCK kCLOCK_PortB
#define BLACKBERRY_TRACKBALL_RIGHT_PIN 2
#define BLACKBERRY_TRACKBALL_UP_PORT PORTA
#define BLACKBERRY_TRACKBALL_UP_GPIO GPIOA
#define BLACKBERRY_TRACKBALL_UP_IRQ PORTA_IRQn
#define BLACKBERRY_TRACKBALL_UP_CLOCK kCLOCK_PortA
#define BLACKBERRY_TRACKBALL_UP_PIN 12
#define BLACKBERRY_TRACKBALL_DOWN_PORT PORTB
#define BLACKBERRY_TRACKBALL_DOWN_GPIO GPIOB
#define BLACKBERRY_TRACKBALL_DOWN_IRQ PORTB_IRQn
#define BLACKBERRY_TRACKBALL_DOWN_CLOCK kCLOCK_PortB
#define BLACKBERRY_TRACKBALL_DOWN_PIN 6
#define BLACKBERRY_TRACKBALL_IRQ_HANDLER1 PORTA_IRQHandler
#define BLACKBERRY_TRACKBALL_IRQ_HANDLER2 PORTB_IRQHandler
// Variables:
extern pointer_delta_t BlackBerryTrackball_PointerDelta;
// Functions:
void BlackberryTrackball_Init(void);
#endif

19
keycluster/src/i2c.h Normal file
View File

@@ -0,0 +1,19 @@
#ifndef __I2C_H__
#define __I2C_H__
// Macros:
#define I2C_BUS_BASEADDR I2C0
#define I2C_BUS_CLK_SRC I2C0_CLK_SRC
#define I2C_BUS_BAUD_RATE 100000 // 100 kHz works even with a 20 meter long bridge cable.
#define I2C_BUS_MUX kPORT_MuxAlt2
#define I2C_BUS_SDA_PORT PORTB
#define I2C_BUS_SDA_CLOCK kCLOCK_PortB
#define I2C_BUS_SDA_PIN 4
#define I2C_BUS_SCL_PORT PORTB
#define I2C_BUS_SCL_CLOCK kCLOCK_PortB
#define I2C_BUS_SCL_PIN 3
#endif

View File

@@ -0,0 +1,33 @@
#include "fsl_i2c.h"
#include "i2c.h"
#include "i2c_watchdog.h"
#include "test_led.h"
#include "init_peripherals.h"
// NOTE: Because of a bug in the ROM bootloader of the KL03Z, the watchdog timer is disabled and cannot be re-enabled.
// See https://community.nxp.com/thread/457893
// Therefore the hardware watchdog timer cannot be used without an extra way to enter bootloader or application mode.
static uint32_t prevWatchdogCounter = 0;
static uint32_t I2cWatchdog_RecoveryCounter; // Counter for how many times we had to recover and restart
void RunWatchdog(void)
{
static volatile uint32_t I2cWatchdog_WatchCounter = 0; // Counter for timer
static int counter = 0;
counter++;
if (counter == 100) { // We get called from KEY_SCANNER_HANDLER() which runs at 1ms, thus scaling down by 100 here to get 100 ms period
counter=0;
TestLed_Toggle();
I2cWatchdog_WatchCounter++;
if (I2cWatchdog_WatchCounter > 10) { // Do not check within the first 1000 ms, as I2C might not be running yet
if (I2C_Watchdog == prevWatchdogCounter) { // Restart I2C if there hasn't been any interrupt during 100 ms. I2C_Watchdog gets incremented for every I2C transaction
I2cWatchdog_RecoveryCounter++;
I2C_SlaveDeinit(I2C_BUS_BASEADDR);
initI2c();
}
}
prevWatchdogCounter = I2C_Watchdog;
}
}

View File

@@ -0,0 +1,18 @@
#ifndef __I2C_WATCHDOG_H__
#define __I2C_WATCHDOG_H__
// Includes:
#include "fsl_lptmr.h"
// Macros:
#define I2C_WATCHDOG_LPTMR_HANDLER LPTMR0_IRQHandler
#define LPTMR_SOURCE_CLOCK CLOCK_GetFreq(kCLOCK_LpoClk)
#define LPTMR_USEC_COUNT 100000U
// Functions:
void RunWatchdog(void);
#endif

View File

@@ -0,0 +1,91 @@
#include "fsl_common.h"
#include "fsl_port.h"
#include "test_led.h"
#include "init_peripherals.h"
#include "i2c_addresses.h"
#include "fsl_i2c.h"
#include "fsl_clock.h"
#include "i2c.h"
#include "led_pwm.h"
#include "slave_protocol_handler.h"
#include "i2c_watchdog.h"
#include "main.h"
#include "module.h"
#include "blackberry_trackball.h"
i2c_slave_config_t slaveConfig;
i2c_slave_handle_t slaveHandle;
uint8_t userData;
uint8_t rxMessagePos;
uint8_t dosBuffer[2];
static void i2cSlaveCallback(I2C_Type *base, i2c_slave_transfer_t *xfer, void *userDataArg)
{
dosBuffer[0] = xfer->event;
dosBuffer[1] = userData;
switch (xfer->event) {
case kI2C_SlaveTransmitEvent:
SlaveTxHandler();
xfer->data = (uint8_t*)&TxMessage;
xfer->dataSize = TxMessage.length + I2C_MESSAGE_HEADER_LENGTH;
break;
case kI2C_SlaveAddressMatchEvent:
rxMessagePos = 0;
break;
case kI2C_SlaveReceiveEvent:
((uint8_t*)&RxMessage)[rxMessagePos++] = userData;
if (RxMessage.length == rxMessagePos-I2C_MESSAGE_HEADER_LENGTH) {
SlaveRxHandler();
}
break;
default:
break;
}
}
void initInterruptPriorities(void)
{
NVIC_SetPriority(I2C0_IRQn, 1);
NVIC_SetPriority(TPM1_IRQn, 1);
NVIC_SetPriority(SPI0_IRQn, 1);
}
void initI2c(void)
{
port_pin_config_t pinConfig = {
.pullSelect = kPORT_PullUp,
};
CLOCK_EnableClock(I2C_BUS_SDA_CLOCK);
CLOCK_EnableClock(I2C_BUS_SCL_CLOCK);
pinConfig.mux = I2C_BUS_MUX;
PORT_SetPinConfig(I2C_BUS_SDA_PORT, I2C_BUS_SDA_PIN, &pinConfig);
PORT_SetPinConfig(I2C_BUS_SCL_PORT, I2C_BUS_SCL_PIN, &pinConfig);
I2C_SlaveGetDefaultConfig(&slaveConfig);
slaveConfig.slaveAddress = I2C_ADDRESS_MODULE_FIRMWARE;
I2C_SlaveInit(I2C_BUS_BASEADDR, &slaveConfig);
I2C_SlaveTransferCreateHandle(I2C_BUS_BASEADDR, &slaveHandle, i2cSlaveCallback, &userData);
I2C_SlaveTransferNonBlocking(I2C_BUS_BASEADDR, &slaveHandle, kI2C_SlaveAddressMatchEvent);
}
void InitLedDriver(void)
{
CLOCK_EnableClock(LED_DRIVER_SDB_CLOCK);
PORT_SetPinMux(LED_DRIVER_SDB_PORT, LED_DRIVER_SDB_PIN, kPORT_MuxAsGpio);
GPIO_PinInit(LED_DRIVER_SDB_GPIO, LED_DRIVER_SDB_PIN, &(gpio_pin_config_t){kGPIO_DigitalOutput, 0});
GPIO_WritePinOutput(LED_DRIVER_SDB_GPIO, LED_DRIVER_SDB_PIN, 1);
}
void InitPeripherals(void)
{
initInterruptPriorities();
InitLedDriver();
TestLed_Init();
LedPwm_Init();
initI2c();
BlackberryTrackball_Init();
}

View File

@@ -0,0 +1,16 @@
#ifndef __INIT_PERIPHERALS_H__
#define __INIT_PERIPHERALS_H__
// Macros:
#define LED_DRIVER_SDB_PORT PORTB
#define LED_DRIVER_SDB_GPIO GPIOB
#define LED_DRIVER_SDB_CLOCK kCLOCK_PortB
#define LED_DRIVER_SDB_PIN 1
// Functions:
void InitPeripherals(void);
void initI2c(void);
#endif

View File

@@ -0,0 +1,22 @@
#include "fsl_lptmr.h"
#include "key_scanner.h"
#include "i2c_watchdog.h"
void KEY_SCANNER_HANDLER(void)
{
KeyMatrix_ScanRow(&keyMatrix);
RunWatchdog();
LPTMR_ClearStatusFlags(KEY_SCANNER_LPTMR_BASEADDR, kLPTMR_TimerCompareFlag);
}
void InitKeyScanner(void)
{
lptmr_config_t lptmrConfig;
LPTMR_GetDefaultConfig(&lptmrConfig);
LPTMR_Init(KEY_SCANNER_LPTMR_BASEADDR, &lptmrConfig);
LPTMR_SetTimerPeriod(KEY_SCANNER_LPTMR_BASEADDR, USEC_TO_COUNT(KEY_SCANNER_INTERVAL_USEC, LPTMR_SOURCE_CLOCK));
LPTMR_EnableInterrupts(KEY_SCANNER_LPTMR_BASEADDR, kLPTMR_TimerInterruptEnable);
EnableIRQ(KEY_SCANNER_LPTMR_IRQ_ID);
LPTMR_StartTimer(KEY_SCANNER_LPTMR_BASEADDR);
}

View File

@@ -0,0 +1,22 @@
#ifndef __KEY_SCANNER_H__
#define __KEY_SCANNER_H__
// Includes:
#include "main.h"
// Macros:
#define LPTMR_SOURCE_CLOCK CLOCK_GetFreq(kCLOCK_LpoClk)
#define KEY_SCANNER_LPTMR_BASEADDR LPTMR0
#define KEY_SCANNER_LPTMR_IRQ_ID LPTMR0_IRQn
#define KEY_SCANNER_HANDLER LPTMR0_IRQHandler
#define KEY_SCANNER_INTERVAL_USEC (1000 / KEYBOARD_MATRIX_ROWS_NUM)
// Functions:
void InitKeyScanner(void);
#endif

30
keycluster/src/led_pwm.c Normal file
View File

@@ -0,0 +1,30 @@
#include "led_pwm.h"
#include "fsl_port.h"
void LedPwm_Init(void)
{
CLOCK_EnableClock(LED_PWM_CLOCK);
PORT_SetPinMux(LED_PWM_PORT, LED_PWM_PIN, kPORT_MuxAlt2);
// Select the clock source for the TPM counter as MCGPLLCLK.
CLOCK_SetTpmClock(1U);
tpm_config_t tpmInfo;
TPM_GetDefaultConfig(&tpmInfo);
TPM_Init(LED_PWM_TPM_BASEADDR, &tpmInfo);
tpm_chnl_pwm_signal_param_t tpmParam[1];
tpmParam[0].chnlNumber = LED_PWM_TPM_CHANNEL;
tpmParam[0].level = kTPM_LowTrue;
tpmParam[0].dutyCyclePercent = 100 - INITIAL_DUTY_CYCLE_PERCENT;
TPM_SetupPwm(LED_PWM_TPM_BASEADDR, tpmParam, 1,
kTPM_EdgeAlignedPwm, TPM_PWM_FREQUENCY, TPM_SOURCE_CLOCK);
TPM_StartTimer(LED_PWM_TPM_BASEADDR, kTPM_SystemClock);
}
void LedPwm_SetBrightness(uint8_t brightnessPercent)
{
TPM_UpdatePwmDutycycle(LED_PWM_TPM_BASEADDR, LED_PWM_TPM_CHANNEL,
kTPM_EdgeAlignedPwm, 100 - brightnessPercent);
}

27
keycluster/src/led_pwm.h Normal file
View File

@@ -0,0 +1,27 @@
#ifndef __LED_PWM_H__
#define __LED_PWM_H__
// Includes:
#include "fsl_tpm.h"
// Macros:
#define LED_PWM_PORT PORTB
#define LED_PWM_CLOCK kCLOCK_PortB
#define LED_PWM_PIN 5
#define LED_PWM_TPM_BASEADDR TPM1
#define LED_PWM_TPM_CHANNEL kTPM_Chnl_1
#define TPM_SOURCE_CLOCK CLOCK_GetFreq(kCLOCK_BusClk)
#define TPM_PWM_FREQUENCY 24000U
#define INITIAL_DUTY_CYCLE_PERCENT 100U
// Functions:
void LedPwm_Init(void);
void LedPwm_SetBrightness(uint8_t brightnessPercent);
#endif

34
keycluster/src/main.c Normal file
View File

@@ -0,0 +1,34 @@
#include "main.h"
#include "slave/init_clock.h"
#include "init_peripherals.h"
#include "bootloader.h"
#include <stdio.h>
#include "key_scanner.h"
#include "module.h"
DEFINE_BOOTLOADER_CONFIG_AREA(I2C_ADDRESS_MODULE_BOOTLOADER)
key_matrix_t keyMatrix = {
.colNum = KEYBOARD_MATRIX_COLS_NUM,
.rowNum = KEYBOARD_MATRIX_ROWS_NUM,
.cols = (key_matrix_pin_t[]) {
{PORTB, GPIOB, kCLOCK_PortB, 11},
{PORTA, GPIOA, kCLOCK_PortA, 6},
},
.rows = (key_matrix_pin_t[]) {
{PORTB, GPIOB, kCLOCK_PortB, 7},
{PORTB, GPIOB, kCLOCK_PortB, 10},
}
};
int main(void)
{
InitClock();
InitPeripherals();
KeyMatrix_Init(&keyMatrix);
InitKeyScanner();
while (1) {
__WFI();
}
}

17
keycluster/src/main.h Normal file
View File

@@ -0,0 +1,17 @@
#ifndef __MAIN_H__
#define __MAIN_H__
// Includes:
#include "key_matrix.h"
// Macros:
#define KEYBOARD_MATRIX_COLS_NUM 2
#define KEYBOARD_MATRIX_ROWS_NUM 2
// Variables:
extern key_matrix_t keyMatrix;
#endif

13
keycluster/src/module.h Normal file
View File

@@ -0,0 +1,13 @@
#ifndef __MODULE_H__
#define __MODULE_H__
// Macros:
#define I2C_ADDRESS_MODULE_FIRMWARE I2C_ADDRESS_LEFT_MODULE_FIRMWARE
#define I2C_ADDRESS_MODULE_BOOTLOADER I2C_ADDRESS_LEFT_MODULE_BOOTLOADER
#define MODULE_PROTOCOL_VERSION 1
#define MODULE_ID ModuleId_KeyClusterLeft
#define MODULE_KEY_COUNT (KEYBOARD_MATRIX_ROWS_NUM * KEYBOARD_MATRIX_COLS_NUM)
#define MODULE_POINTER_COUNT 1
#endif

View File

@@ -0,0 +1,115 @@
#include "slave_protocol_handler.h"
#include "test_led.h"
#include "main.h"
#include "i2c_addresses.h"
#include "i2c.h"
#include "led_pwm.h"
#include "slave_protocol.h"
#include "main.h"
#include "init_peripherals.h"
#include "bool_array_converter.h"
#include "bootloader.h"
#include "module.h"
#include "versions.h"
#include "blackberry_trackball.h"
i2c_message_t RxMessage;
i2c_message_t TxMessage;
static version_t moduleProtocolVersion = {
MODULE_PROTOCOL_MAJOR_VERSION,
MODULE_PROTOCOL_MINOR_VERSION,
MODULE_PROTOCOL_PATCH_VERSION,
};
static version_t firmwareVersion = {
FIRMWARE_MAJOR_VERSION,
FIRMWARE_MINOR_VERSION,
FIRMWARE_PATCH_VERSION,
};
void SlaveRxHandler(void)
{
if (!CRC16_IsMessageValid(&RxMessage)) {
TxMessage.length = 0;
return;
}
uint8_t commandId = RxMessage.data[0];
switch (commandId) {
case SlaveCommand_JumpToBootloader:
NVIC_SystemReset();
break;
case SlaveCommand_SetTestLed:
TxMessage.length = 0;
bool isLedOn = RxMessage.data[1];
TestLed_Set(isLedOn);
break;
case SlaveCommand_SetLedPwmBrightness:
TxMessage.length = 0;
uint8_t brightnessPercent = RxMessage.data[1];
LedPwm_SetBrightness(brightnessPercent);
break;
}
}
void SlaveTxHandler(void)
{
uint8_t commandId = RxMessage.data[0];
switch (commandId) {
case SlaveCommand_RequestProperty: {
uint8_t propertyId = RxMessage.data[1];
switch (propertyId) {
case SlaveProperty_Sync: {
memcpy(TxMessage.data, SlaveSyncString, SLAVE_SYNC_STRING_LENGTH);
TxMessage.length = SLAVE_SYNC_STRING_LENGTH;
break;
}
case SlaveProperty_ModuleProtocolVersion: {
memcpy(TxMessage.data, &moduleProtocolVersion, sizeof(version_t));
TxMessage.length = sizeof(version_t);
break;
}
case SlaveProperty_FirmwareVersion: {
memcpy(TxMessage.data, &firmwareVersion, sizeof(version_t));
TxMessage.length = sizeof(version_t);
break;
}
case SlaveProperty_ModuleId: {
TxMessage.data[0] = MODULE_ID;
TxMessage.length = 1;
break;
}
case SlaveProperty_KeyCount: {
TxMessage.data[0] = MODULE_KEY_COUNT;
TxMessage.length = 1;
break;
}
case SlaveProperty_PointerCount: {
TxMessage.data[0] = MODULE_POINTER_COUNT;
TxMessage.length = 1;
break;
}
}
break;
}
case SlaveCommand_RequestKeyStates:
BoolBytesToBits(keyMatrix.keyStates, TxMessage.data, MODULE_KEY_COUNT);
uint8_t messageLength = BOOL_BYTES_TO_BITS_COUNT(MODULE_KEY_COUNT);
if (MODULE_POINTER_COUNT) {
pointer_delta_t *pointerDelta = (pointer_delta_t*)(TxMessage.data + messageLength);
pointerDelta->x = BlackBerryTrackball_PointerDelta.x;
pointerDelta->y = BlackBerryTrackball_PointerDelta.y;
BlackBerryTrackball_PointerDelta.x = 0;
BlackBerryTrackball_PointerDelta.y = 0;
if (keyMatrix.keyStates[0]) {
pointerDelta->x = 1;
}
messageLength += sizeof(pointer_delta_t);
}
TxMessage.length = messageLength;
break;
}
CRC16_UpdateMessageChecksum(&TxMessage);
}

View File

@@ -0,0 +1,20 @@
#ifndef __SLAVE_PROTOCOL_HANDLER_H__
#define __SLAVE_PROTOCOL_HANDLER_H__
// Includes:
#include "fsl_port.h"
#include "crc16.h"
#include "slave_protocol.h"
// Variables:
extern i2c_message_t RxMessage;
extern i2c_message_t TxMessage;
// Functions:
void SlaveRxHandler(void);
void SlaveTxHandler(void);
#endif

10
keycluster/src/test_led.c Normal file
View File

@@ -0,0 +1,10 @@
#include "test_led.h"
#include "fsl_port.h"
extern void TestLed_Init(void)
{
CLOCK_EnableClock(TEST_LED_CLOCK);
PORT_SetPinMux(TEST_LED_PORT, TEST_LED_PIN, kPORT_MuxAsGpio);
GPIO_PinInit(TEST_LED_GPIO, TEST_LED_PIN, &(gpio_pin_config_t){kGPIO_DigitalOutput, 0});
TestLed_On();
}

42
keycluster/src/test_led.h Normal file
View File

@@ -0,0 +1,42 @@
#ifndef __TEST_LED_H__
#define __TEST_LED_H__
// Includes:
#include "fsl_gpio.h"
// Macros:
#define LOGIC_LED_ON 0U
#define LOGIC_LED_OFF 1U
#define TEST_LED_GPIO GPIOB
#define TEST_LED_PORT PORTB
#define TEST_LED_CLOCK kCLOCK_PortB
#define TEST_LED_PIN 13
static inline void TestLed_On(void)
{
GPIO_SetPinsOutput(TEST_LED_GPIO, 1U << TEST_LED_PIN);
}
static inline void TestLed_Off(void)
{
GPIO_ClearPinsOutput(TEST_LED_GPIO, 1U << TEST_LED_PIN);
}
static inline void TestLed_Set(bool state)
{
GPIO_WritePinOutput(TEST_LED_GPIO, TEST_LED_PIN, state);
}
static inline void TestLed_Toggle(void)
{
GPIO_TogglePinsOutput(TEST_LED_GPIO, 1U << TEST_LED_PIN);
}
// Functions:
void TestLed_Init(void);
#endif

View File

@@ -10,6 +10,7 @@
#include "slave_protocol_handler.h"
#include "i2c_watchdog.h"
#include "main.h"
#include "module.h"
i2c_slave_config_t slaveConfig;
i2c_slave_handle_t slaveHandle;
@@ -64,7 +65,7 @@ void initI2c(void)
PORT_SetPinConfig(I2C_BUS_SCL_PORT, I2C_BUS_SCL_PIN, &pinConfig);
I2C_SlaveGetDefaultConfig(&slaveConfig);
slaveConfig.slaveAddress = I2C_ADDRESS_LEFT_KEYBOARD_HALF_FIRMWARE;
slaveConfig.slaveAddress = I2C_ADDRESS_MODULE_FIRMWARE;
I2C_SlaveInit(I2C_BUS_BASEADDR, &slaveConfig);
I2C_SlaveTransferCreateHandle(I2C_BUS_BASEADDR, &slaveHandle, i2cSlaveCallback, &userData);
I2C_SlaveTransferNonBlocking(I2C_BUS_BASEADDR, &slaveHandle, kI2C_SlaveAddressMatchEvent);

View File

@@ -5,9 +5,7 @@
void KEY_SCANNER_HANDLER(void)
{
KeyMatrix_ScanRow(&keyMatrix);
#ifdef I2C_WATCHDOG
RunWatchdog();
#endif
LPTMR_ClearStatusFlags(KEY_SCANNER_LPTMR_BASEADDR, kLPTMR_TimerCompareFlag);
}

View File

@@ -4,8 +4,9 @@
#include "bootloader.h"
#include <stdio.h>
#include "key_scanner.h"
#include "module.h"
DEFINE_BOOTLOADER_CONFIG_AREA(I2C_ADDRESS_LEFT_KEYBOARD_HALF_BOOTLOADER)
DEFINE_BOOTLOADER_CONFIG_AREA(I2C_ADDRESS_MODULE_BOOTLOADER)
key_matrix_t keyMatrix = {
.colNum = KEYBOARD_MATRIX_COLS_NUM,

View File

@@ -3,6 +3,8 @@
// Macros:
#define I2C_ADDRESS_MODULE_FIRMWARE I2C_ADDRESS_LEFT_KEYBOARD_HALF_FIRMWARE
#define I2C_ADDRESS_MODULE_BOOTLOADER I2C_ADDRESS_LEFT_KEYBOARD_HALF_BOOTLOADER
#define MODULE_PROTOCOL_VERSION 1
#define MODULE_ID ModuleId_LeftKeyboardHalf
#define MODULE_KEY_COUNT (KEYBOARD_MATRIX_ROWS_NUM * KEYBOARD_MATRIX_COLS_NUM)

View File

@@ -48,10 +48,12 @@
SerializedMouseAction_ScrollRight,
SerializedMouseAction_Accelerate,
SerializedMouseAction_Decelerate,
SerializedMouseAction_Last = SerializedMouseAction_Decelerate,
SerializedMouseAction_Button_4,
SerializedMouseAction_Button_5,
SerializedMouseAction_Button_6,
SerializedMouseAction_Button_7,
SerializedMouseAction_Button_8,
SerializedMouseAction_Last = SerializedMouseAction_Button_8,
} serialized_mouse_action_t;
// Functions:

View File

@@ -6,6 +6,7 @@
#include "i2c.h"
#include "i2c_watchdog.h"
#include "init_peripherals.h"
#include "peripherals/test_led.h"
uint32_t I2cWatchdog_WatchCounter;
uint32_t I2cWatchdog_RecoveryCounter;
@@ -26,6 +27,7 @@ void PIT_I2C_WATCHDOG_HANDLER(void)
prevWatchdogCounter = I2C_Watchdog;
PIT_ClearStatusFlags(PIT, PIT_I2C_WATCHDOG_CHANNEL, PIT_TFLG_TIF_MASK);
TestLed_Toggle();
}
void InitI2cWatchdog(void)

View File

@@ -13,7 +13,6 @@
uint8_t timestamp;
bool previous : 1;
bool current : 1;
bool suppressed : 1;
bool debouncing : 1;
} key_state_t;

View File

@@ -5,7 +5,6 @@
#include "config_parser/parse_keymap.h"
#include "config_parser/config_globals.h"
#include "macros.h"
#include "usb_report_updater.h"
keymap_reference_t AllKeymaps[MAX_KEYMAP_NUM] = {
{
@@ -25,7 +24,6 @@ void SwitchKeymapById(uint8_t index)
ValidatedUserConfigBuffer.offset = AllKeymaps[index].offset;
ParseKeymap(&ValidatedUserConfigBuffer, index, AllKeymapsCount, AllMacrosCount);
LedDisplay_UpdateText();
KeymapChanged = true;
}
bool SwitchKeymapByAbbreviation(uint8_t length, char *abbrev)

View File

@@ -15,7 +15,7 @@ void updateLayerStates(void)
for (uint8_t slotId=0; slotId<SLOT_COUNT; slotId++) {
for (uint8_t keyId=0; keyId<MAX_KEY_COUNT_PER_MODULE; keyId++) {
key_state_t *keyState = &KeyStates[slotId][keyId];
if (keyState->current && !keyState->suppressed) {
if (keyState->current) {
key_action_t action = CurrentKeymap[LayerId_Base][slotId][keyId];
if (action.type == KeyActionType_SwitchLayer) {
if (action.switchLayer.mode != SwitchLayerMode_Toggle) {
@@ -70,3 +70,14 @@ layer_id_t GetActiveLayer()
return heldLayer;
}
bool IsLayerHeld(void)
{
for (layer_id_t layerId = LayerId_Mod; layerId <= LayerId_Mouse; layerId++) {
if (heldLayers[layerId]) {
return true;
}
}
return false;
}

View File

@@ -25,6 +25,7 @@
// Functions:
layer_id_t GetActiveLayer();
layer_id_t GetActiveLayer(void);
bool IsLayerHeld(void);
#endif

View File

@@ -218,7 +218,7 @@ void deleteSystemScancode(uint8_t scancode)
}
}
void addScancode(uint16_t scancode, macro_sub_action_t type)
void addScancode(uint16_t scancode, keystroke_type_t type)
{
switch (type) {
case KeystrokeType_Basic:
@@ -233,7 +233,7 @@ void addScancode(uint16_t scancode, macro_sub_action_t type)
}
}
void deleteScancode(uint16_t scancode, macro_sub_action_t type)
void deleteScancode(uint16_t scancode, keystroke_type_t type)
{
switch (type) {
case KeystrokeType_Basic:
@@ -296,7 +296,7 @@ bool processMouseButtonAction(void)
{
static bool pressStarted;
switch (currentMacroAction.key.action) {
switch (currentMacroAction.mouseButton.action) {
case MacroSubAction_Tap:
if (!pressStarted) {
pressStarted = true;
@@ -401,6 +401,9 @@ bool processCurrentMacroAction(void)
void Macros_StartMacro(uint8_t index)
{
if(AllMacros[index].macroActionsCount == 0) {
return;
}
MacroPlaying = true;
currentMacroIndex = index;
currentMacroActionIndex = 0;

View File

@@ -9,6 +9,17 @@
#include "key_states.h"
uhk_module_state_t UhkModuleStates[UHK_MODULE_MAX_COUNT];
uint8_t UhkModuleSlaveDriver_SlotIdToDriverId(uint8_t slotId)
{
return slotId-1;
}
uint8_t UhkModuleSlaveDriver_DriverIdToSlotId(uint8_t uhkModuleDriverId)
{
return uhkModuleDriverId+1;
}
static uint8_t keyStatesBuffer[MAX_KEY_COUNT_PER_MODULE];
static i2c_message_t txMessage;
@@ -17,13 +28,13 @@ static uhk_module_i2c_addresses_t moduleIdsToI2cAddresses[] = {
.firmwareI2cAddress = I2C_ADDRESS_LEFT_KEYBOARD_HALF_FIRMWARE,
.bootloaderI2cAddress = I2C_ADDRESS_LEFT_KEYBOARD_HALF_BOOTLOADER
},
{ // UhkModuleDriverId_LeftAddon
.firmwareI2cAddress = I2C_ADDRESS_LEFT_ADDON_FIRMWARE,
.bootloaderI2cAddress = I2C_ADDRESS_LEFT_ADDON_BOOTLOADER
{ // UhkModuleDriverId_LeftModule
.firmwareI2cAddress = I2C_ADDRESS_LEFT_MODULE_FIRMWARE,
.bootloaderI2cAddress = I2C_ADDRESS_LEFT_MODULE_BOOTLOADER
},
{ // UhkModuleDriverId_RightAddon
.firmwareI2cAddress = I2C_ADDRESS_RIGHT_ADDON_FIRMWARE,
.bootloaderI2cAddress = I2C_ADDRESS_RIGHT_ADDON_BOOTLOADER
{ // UhkModuleDriverId_RightModule
.firmwareI2cAddress = I2C_ADDRESS_RIGHT_MODULE_FIRMWARE,
.bootloaderI2cAddress = I2C_ADDRESS_RIGHT_MODULE_BOOTLOADER
},
};
@@ -55,6 +66,9 @@ void UhkModuleSlaveDriver_Init(uint8_t uhkModuleDriverId)
uhk_module_i2c_addresses_t *uhkModuleI2cAddresses = moduleIdsToI2cAddresses + uhkModuleDriverId;
uhkModuleState->firmwareI2cAddress = uhkModuleI2cAddresses->firmwareI2cAddress;
uhkModuleState->bootloaderI2cAddress = uhkModuleI2cAddresses->bootloaderI2cAddress;
uhkModuleState->pointerDelta.x = 0;
uhkModuleState->pointerDelta.y = 0;
}
status_t UhkModuleSlaveDriver_Update(uint8_t uhkModuleDriverId)
@@ -221,11 +235,17 @@ status_t UhkModuleSlaveDriver_Update(uint8_t uhkModuleDriverId)
break;
case UhkModulePhase_ProcessKeystates:
if (CRC16_IsMessageValid(rxMessage)) {
uint8_t slotId = uhkModuleDriverId + 1;
uint8_t slotId = UhkModuleSlaveDriver_DriverIdToSlotId(uhkModuleDriverId);
BoolBitsToBytes(rxMessage->data, keyStatesBuffer, uhkModuleState->keyCount);
for (uint8_t keyId=0; keyId<uhkModuleState->keyCount; keyId++) {
for (uint8_t keyId=0; keyId < uhkModuleState->keyCount; keyId++) {
KeyStates[slotId][keyId].current = keyStatesBuffer[keyId];
}
if (uhkModuleState->pointerCount) {
uint8_t keyStatesLength = BOOL_BYTES_TO_BITS_COUNT(uhkModuleState->keyCount);
pointer_delta_t *pointerDelta = (pointer_delta_t*)(rxMessage->data + keyStatesLength);
uhkModuleState->pointerDelta.x += pointerDelta->x;
uhkModuleState->pointerDelta.y += pointerDelta->y;
}
}
status = kStatus_Uhk_IdleCycle;
*uhkModulePhase = UhkModulePhase_SetTestLed;

View File

@@ -6,20 +6,19 @@
#include "fsl_common.h"
#include "crc16.h"
#include "versions.h"
#include "usb_interfaces/usb_interface_mouse.h"
// Macros:
#define UHK_MODULE_MAX_COUNT 3
#define MAX_PWM_BRIGHTNESS 0x64
#define SLOT_ID_TO_UHK_MODULE_DRIVER_ID(slotId) ((slotId)-1)
#define UHK_MODULE_DRIVER_ID_TO_SLOT_ID(uhkModuleDriverId) ((uhkModuleDriverId)+1)
// Typedefs:
typedef enum {
UhkModuleDriverId_LeftKeyboardHalf,
UhkModuleDriverId_LeftAddon,
UhkModuleDriverId_RightAddon,
UhkModuleDriverId_LeftModule,
UhkModuleDriverId_RightModule,
} uhk_module_id_t;
typedef enum {
@@ -83,6 +82,7 @@
uint8_t bootloaderI2cAddress;
uint8_t keyCount;
uint8_t pointerCount;
pointer_delta_t pointerDelta;
} uhk_module_state_t;
typedef struct {
@@ -96,6 +96,9 @@
// Functions:
uint8_t UhkModuleSlaveDriver_SlotIdToDriverId(uint8_t slotId);
uint8_t UhkModuleSlaveDriver_DriverIdToSlotId(uint8_t uhkModuleDriverId);
void UhkModuleSlaveDriver_Init(uint8_t uhkModuleDriverId);
status_t UhkModuleSlaveDriver_Update(uint8_t uhkModuleDriverId);
void UhkModuleSlaveDriver_Disconnect(uint8_t uhkModuleDriverId);

View File

@@ -24,12 +24,12 @@ uhk_slave_t Slaves[] = {
{
.init = UhkModuleSlaveDriver_Init,
.update = UhkModuleSlaveDriver_Update,
.perDriverId = UhkModuleDriverId_LeftAddon,
.perDriverId = UhkModuleDriverId_LeftModule,
},
{
.init = UhkModuleSlaveDriver_Init,
.update = UhkModuleSlaveDriver_Update,
.perDriverId = UhkModuleDriverId_RightAddon,
.perDriverId = UhkModuleDriverId_RightModule,
},
{
.init = LedSlaveDriver_Init,

View File

@@ -10,6 +10,6 @@ void UsbCommand_GetKeyboardState(void)
SetUsbTxBufferUint8(1, IsEepromBusy);
SetUsbTxBufferUint8(2, MERGE_SENSOR_IS_MERGED);
SetUsbTxBufferUint8(3, UhkModuleStates[UhkModuleDriverId_LeftKeyboardHalf].moduleId);
SetUsbTxBufferUint8(4, UhkModuleStates[UhkModuleDriverId_LeftAddon].moduleId);
SetUsbTxBufferUint8(5, UhkModuleStates[UhkModuleDriverId_RightAddon].moduleId);
SetUsbTxBufferUint8(4, UhkModuleStates[UhkModuleDriverId_LeftModule].moduleId);
SetUsbTxBufferUint8(5, UhkModuleStates[UhkModuleDriverId_RightModule].moduleId);
}

View File

@@ -15,7 +15,7 @@ void UsbCommand_GetModuleProperty()
module_property_id_t modulePropertyId = GetUsbRxBufferUint8(2);
switch (modulePropertyId) {
case ModulePropertyId_VersionNumbers: {
uint8_t moduleDriverId = SLOT_ID_TO_UHK_MODULE_DRIVER_ID(slotId);
uint8_t moduleDriverId = UhkModuleSlaveDriver_SlotIdToDriverId(slotId);
uhk_module_state_t *moduleState = UhkModuleStates + moduleDriverId;
GenericHidOutBuffer[1] = moduleState->moduleId;
memcpy(GenericHidOutBuffer + 2, &moduleState->moduleProtocolVersion, sizeof(version_t));

View File

@@ -12,6 +12,6 @@ void UsbCommand_JumpToModuleBootloader(void)
return;
}
uint8_t uhkModuleDriverId = SLOT_ID_TO_UHK_MODULE_DRIVER_ID(slotId);
uint8_t uhkModuleDriverId = UhkModuleSlaveDriver_SlotIdToDriverId(slotId);
UhkModuleStates[uhkModuleDriverId].phase = UhkModulePhase_JumpToBootloader;
}

View File

@@ -25,8 +25,7 @@ static uint16_t DoubleTapSwitchLayerReleaseTimeout = 200;
static bool activeMouseStates[ACTIVE_MOUSE_STATES_COUNT];
bool TestUsbStack = false;
bool KeymapChanged = false;
static uint8_t layerCache[SLOT_COUNT][MAX_KEY_COUNT_PER_MODULE];
static key_action_t actionCache[SLOT_COUNT][MAX_KEY_COUNT_PER_MODULE];
volatile uint8_t UsbReportUpdateSemaphore = 0;
@@ -176,6 +175,16 @@ static void processMouseActions()
MouseScrollState.xOut = 0;
MouseScrollState.yOut = 0;
for (uint8_t moduleId=0; moduleId<UHK_MODULE_MAX_COUNT; moduleId++) {
uhk_module_state_t *moduleState = UhkModuleStates + moduleId;
if (moduleState->pointerCount) {
ActiveUsbMouseReport->wheelX += moduleState->pointerDelta.x;
ActiveUsbMouseReport->wheelY -= moduleState->pointerDelta.y;
moduleState->pointerDelta.x = 0;
moduleState->pointerDelta.y = 0;
}
}
// The following line makes the firmware crash for some reason:
// SetDebugBufferFloat(60, mouseScrollState.currentSpeed);
// TODO: Figure out why.
@@ -238,72 +247,84 @@ static void handleSwitchLayerAction(key_state_t *keyState, key_action_t *action)
static uint8_t basicScancodeIndex = 0;
static uint8_t mediaScancodeIndex = 0;
static uint8_t systemScancodeIndex = 0;
static uint8_t stickyModifiers;
static uint8_t stickyModifiers, stickySlotId, stickyKeyId;
static uint8_t secondaryRoleState = SecondaryRoleState_Released;
static uint8_t secondaryRoleSlotId;
static uint8_t secondaryRoleKeyId;
static secondary_role_t secondaryRole;
static void applyKeyAction(key_state_t *keyState, key_action_t *action)
static void applyKeyAction(key_state_t *keyState, key_action_t *action, uint8_t slotId, uint8_t keyId)
{
if (keyState->suppressed) {
return;
}
if (keyState->current) {
handleSwitchLayerAction(keyState, action);
handleSwitchLayerAction(keyState, action);
switch (action->type) {
case KeyActionType_Keystroke:
if (action->keystroke.scancode) {
if (!keyState->previous) {
stickyModifiers = action->keystroke.modifiers;
switch (action->type) {
case KeyActionType_Keystroke:
if (action->keystroke.scancode) {
if (!keyState->previous) {
stickyModifiers = action->keystroke.modifiers;
stickySlotId = slotId;
stickyKeyId = keyId;
}
} else {
ActiveUsbBasicKeyboardReport->modifiers |= action->keystroke.modifiers;
}
} else {
ActiveUsbBasicKeyboardReport->modifiers |= action->keystroke.modifiers;
}
switch (action->keystroke.keystrokeType) {
case KeystrokeType_Basic:
if (basicScancodeIndex >= USB_BASIC_KEYBOARD_MAX_KEYS || action->keystroke.scancode == 0) {
switch (action->keystroke.keystrokeType) {
case KeystrokeType_Basic:
if (basicScancodeIndex >= USB_BASIC_KEYBOARD_MAX_KEYS || action->keystroke.scancode == 0) {
break;
}
ActiveUsbBasicKeyboardReport->scancodes[basicScancodeIndex++] = action->keystroke.scancode;
break;
}
ActiveUsbBasicKeyboardReport->scancodes[basicScancodeIndex++] = action->keystroke.scancode;
break;
case KeystrokeType_Media:
if (mediaScancodeIndex >= USB_MEDIA_KEYBOARD_MAX_KEYS) {
case KeystrokeType_Media:
if (mediaScancodeIndex >= USB_MEDIA_KEYBOARD_MAX_KEYS) {
break;
}
ActiveUsbMediaKeyboardReport->scancodes[mediaScancodeIndex++] = action->keystroke.scancode;
break;
}
ActiveUsbMediaKeyboardReport->scancodes[mediaScancodeIndex++] = action->keystroke.scancode;
break;
case KeystrokeType_System:
if (systemScancodeIndex >= USB_SYSTEM_KEYBOARD_MAX_KEYS) {
case KeystrokeType_System:
if (systemScancodeIndex >= USB_SYSTEM_KEYBOARD_MAX_KEYS) {
break;
}
ActiveUsbSystemKeyboardReport->scancodes[systemScancodeIndex++] = action->keystroke.scancode;
break;
}
break;
case KeyActionType_Mouse:
if (!keyState->previous) {
stickyModifiers = 0;
}
activeMouseStates[action->mouseAction] = true;
break;
case KeyActionType_SwitchLayer:
// Handled by handleSwitchLayerAction()
break;
case KeyActionType_SwitchKeymap:
if (!keyState->previous) {
stickyModifiers = 0;
secondaryRoleState = SecondaryRoleState_Released;
SwitchKeymapById(action->switchKeymap.keymapId);
}
break;
case KeyActionType_PlayMacro:
if (!keyState->previous) {
stickyModifiers = 0;
Macros_StartMacro(action->playMacro.macroId);
}
break;
}
} else {
switch (action->type) {
case KeyActionType_Keystroke:
if (keyState->previous) {
if (slotId == stickySlotId && keyId == stickyKeyId) {
if (!IsLayerHeld() && !(secondaryRoleState == SecondaryRoleState_Triggered && IS_SECONDARY_ROLE_LAYER_SWITCHER(secondaryRole))) {
stickyModifiers = 0;
}
}
ActiveUsbSystemKeyboardReport->scancodes[systemScancodeIndex++] = action->keystroke.scancode;
break;
}
break;
case KeyActionType_Mouse:
if (!keyState->previous) {
stickyModifiers = 0;
}
activeMouseStates[action->mouseAction] = true;
break;
case KeyActionType_SwitchLayer:
// Handled by handleSwitchLayerAction()
break;
case KeyActionType_SwitchKeymap:
if (!keyState->previous) {
stickyModifiers = 0;
secondaryRoleState = SecondaryRoleState_Released;
SwitchKeymapById(action->switchKeymap.keymapId);
}
break;
case KeyActionType_PlayMacro:
if (!keyState->previous) {
stickyModifiers = 0;
Macros_StartMacro(action->playMacro.macroId);
}
break;
}
break;
}
}
}
@@ -335,8 +356,6 @@ static void updateActiveUsbReports(void)
if (layerChanged) {
stickyModifiers = 0;
}
bool keymapChangedLastCycle = KeymapChanged;
KeymapChanged = false;
LedDisplay_SetLayer(activeLayer);
if (TestUsbStack) {
@@ -383,38 +402,36 @@ static void updateActiveUsbReports(void)
secondaryRoleState = SecondaryRoleState_Triggered;
keyState->current = false;
} else {
layerCache[slotId][keyId] = activeLayer;
actionCache[slotId][keyId] = CurrentKeymap[activeLayer][slotId][keyId];
}
}
action = &CurrentKeymap[layerCache[slotId][keyId]][slotId][keyId];
action = &actionCache[slotId][keyId];
if (keyState->current) {
if ((KeymapChanged || keymapChangedLastCycle) && keyState->previous) {
keyState->suppressed = true;
} else if (action->type == KeyActionType_Keystroke && action->keystroke.secondaryRole) {
if (action->type == KeyActionType_Keystroke && action->keystroke.secondaryRole) {
// Press released secondary role key.
if (!keyState->previous && secondaryRoleState == SecondaryRoleState_Released) {
secondaryRoleState = SecondaryRoleState_Pressed;
secondaryRoleSlotId = slotId;
secondaryRoleKeyId = keyId;
secondaryRole = action->keystroke.secondaryRole;
keyState->suppressed = true;
}
} else {
applyKeyAction(keyState, action);
applyKeyAction(keyState, action, slotId, keyId);
}
} else {
keyState->suppressed = false;
// Release secondary role key.
if (keyState->previous && secondaryRoleSlotId == slotId && secondaryRoleKeyId == keyId) {
if (keyState->previous && secondaryRoleSlotId == slotId && secondaryRoleKeyId == keyId && secondaryRoleState != SecondaryRoleState_Released) {
// Trigger primary role.
if (secondaryRoleState == SecondaryRoleState_Pressed) {
keyState->previous = false;
applyKeyAction(keyState, action);
keyState->current = true;
applyKeyAction(keyState, action, slotId, keyId);
}
secondaryRoleState = SecondaryRoleState_Released;
} else {
applyKeyAction(keyState, action, slotId, keyId);
}
}

View File

@@ -74,7 +74,6 @@
extern uint32_t UsbReportUpdateCounter;
extern volatile uint8_t UsbReportUpdateSemaphore;
extern bool TestUsbStack;
extern bool KeymapChanged;
// Functions:

View File

@@ -0,0 +1,7 @@
speed 4000
device MKL03Z32xxx4
connect
loadfile build_make/uhk_keycluster.hex
RSetType 2
r
qc

View File

@@ -11,10 +11,8 @@ const package = JSON.parse(fs.readFileSync(`${__dirname}/package.json`));
const version = package.firmwareVersion;
const releaseName = `uhk-firmware-${version}`;
const releaseDir = `${__dirname}/${releaseName}`;
const modulesDir = `${releaseDir}/modules`;
const releaseFile = `${__dirname}/${releaseName}.tar.bz2`;
const leftFirmwareFile = `${__dirname}/../left/build_make/uhk_left.bin`;
const usbDir = `${__dirname}/../lib/agent/packages/usb`;
const agentDir = `${__dirname}/../lib/agent`;
const deviceSourceFirmwares = package.devices.map(device => `${__dirname}/../${device.source}`);
const moduleSourceFirmwares = package.modules.map(module => `${__dirname}/../${module.source}`);
@@ -23,14 +21,16 @@ rm('-rf', releaseDir, releaseFile, deviceSourceFirmwares, moduleSourceFirmwares)
exec(`cd ${__dirname}/../left; make clean; make -j8`);
exec(`cd ${__dirname}/../right; make clean; make -j8`);
exec(`git pull origin master; git checkout master`, { cwd: agentDir });
exec(`npm ci`, { cwd: agentDir });
for (const device of package.devices) {
const deviceDir = `${releaseDir}/devices/${device.name}`;
const deviceSource = `${__dirname}/../${device.source}`;
mkdir('-p', deviceDir);
chmod(644, deviceSource);
cp(deviceSource, `${deviceDir}/firmware.hex`);
exec(`cd ${usbDir}; git pull origin master; git checkout master`);
exec(`${usbDir}/user-config-json-to-bin.ts ${deviceDir}/config.bin`);
exec(`npm run convert-user-config-to-bin -- ${deviceDir}/config.bin`, { cwd: agentDir });
}
for (const module of package.modules) {

View File

@@ -15,10 +15,10 @@
"commander": "^2.11.0",
"shelljs": "^0.7.8"
},
"firmwareVersion": "8.5.1",
"firmwareVersion": "8.6.0",
"deviceProtocolVersion": "4.5.0",
"moduleProtocolVersion": "4.0.0",
"userConfigVersion": "4.1.0",
"moduleProtocolVersion": "4.1.0",
"userConfigVersion": "4.1.1",
"hardwareConfigVersion": "1.0.0",
"devices": [
{

View File

@@ -29,11 +29,11 @@
#define I2C_ADDRESS_LEFT_KEYBOARD_HALF_FIRMWARE 0x08
#define I2C_ADDRESS_LEFT_KEYBOARD_HALF_BOOTLOADER 0x10
#define I2C_ADDRESS_RIGHT_IQS5XX_FIRMWARE 0x15 // Touchpad
#define I2C_ADDRESS_LEFT_ADDON_FIRMWARE 0x18
#define I2C_ADDRESS_LEFT_ADDON_BOOTLOADER 0x20
#define I2C_ADDRESS_LEFT_MODULE_FIRMWARE 0x18
#define I2C_ADDRESS_LEFT_MODULE_BOOTLOADER 0x20
#define I2C_ADDRESS_LEFT_IQS5XX_FIRMWARE 0x25 // Touchpad
#define I2C_ADDRESS_RIGHT_ADDON_FIRMWARE 0x28
#define I2C_ADDRESS_RIGHT_ADDON_BOOTLOADER 0x30
#define I2C_ADDRESS_RIGHT_MODULE_FIRMWARE 0x28
#define I2C_ADDRESS_RIGHT_MODULE_BOOTLOADER 0x30
#define I2C_ADDRESS_RIGHT_IQS5XX_BOOTLOADER 0x55 // Touchpad
#define I2C_ADDRESS_LEFT_IQS5XX_BOOTLOADER 0x65 // Touchpad
#define I2C_ADDRESS_IS31FL3731_LEFT 0x74 // LED driver

View File

@@ -24,19 +24,19 @@ void KeyMatrix_ScanRow(key_matrix_t *keyMatrix)
{
uint8_t *keyState = keyMatrix->keyStates + keyMatrix->currentRowNum * keyMatrix->colNum;
key_matrix_pin_t *row = keyMatrix->rows + keyMatrix->currentRowNum;
GPIO_Type *rowGpio = row->gpio;
uint32_t rowPin = row->pin;
GPIO_WritePinOutput(rowGpio, rowPin, 1);
key_matrix_pin_t *colEnd = keyMatrix->cols + keyMatrix->colNum;
for (key_matrix_pin_t *col = keyMatrix->cols; col<colEnd; col++) {
*(keyState++) = GPIO_ReadPinInput(col->gpio, col->pin);
}
GPIO_WritePinOutput(rowGpio, rowPin, 0);
GPIO_WritePinOutput(row->gpio, row->pin, 0);
if (++keyMatrix->currentRowNum >= keyMatrix->rowNum) {
keyMatrix->currentRowNum = 0;
}
// This should come last to maintain the strobe for as long as possible to minimize the chance of chatter.
row = keyMatrix->rows + keyMatrix->currentRowNum;
GPIO_WritePinOutput(row->gpio, row->pin, 1);
}

View File

@@ -48,6 +48,11 @@
uint8_t data[I2C_MESSAGE_MAX_PAYLOAD_LENGTH];
} ATTR_PACKED i2c_message_t;
typedef struct {
int16_t x;
int16_t y;
} ATTR_PACKED pointer_delta_t;
// Variables:
extern char SlaveSyncString[];

View File

@@ -19,20 +19,20 @@
// Variables:
#define FIRMWARE_MAJOR_VERSION 8
#define FIRMWARE_MINOR_VERSION 5
#define FIRMWARE_PATCH_VERSION 1
#define FIRMWARE_MINOR_VERSION 6
#define FIRMWARE_PATCH_VERSION 0
#define DEVICE_PROTOCOL_MAJOR_VERSION 4
#define DEVICE_PROTOCOL_MINOR_VERSION 5
#define DEVICE_PROTOCOL_PATCH_VERSION 0
#define MODULE_PROTOCOL_MAJOR_VERSION 4
#define MODULE_PROTOCOL_MINOR_VERSION 0
#define MODULE_PROTOCOL_MINOR_VERSION 1
#define MODULE_PROTOCOL_PATCH_VERSION 0
#define USER_CONFIG_MAJOR_VERSION 4
#define USER_CONFIG_MINOR_VERSION 1
#define USER_CONFIG_PATCH_VERSION 0
#define USER_CONFIG_PATCH_VERSION 1
#define HARDWARE_CONFIG_MAJOR_VERSION 1
#define HARDWARE_CONFIG_MINOR_VERSION 0