László Monda
d1955ffa54
Don't call I2C_MasterInit() as the left keyboard half is an I2C slave.
2017-02-05 14:25:18 +01:00
László Monda
fc0fc4a3f4
Start to implement the fully asynchronous bridge protocol scheduler and use it to transfer key and LED state.
2017-02-03 01:37:25 +01:00
László Monda
d8761a95ba
Use >= relations instead of == for comparing UHK_PCB_MAJOR_VERSION.
2017-01-21 02:20:47 +01:00
László Monda
bcab294256
Add uhk-right v7 release kboot build configuration.
2017-01-21 02:13:52 +01:00
László Monda
1419a3bd48
Relocate the firmware so that it works with KBOOT. This also means that KBOOT must also be uploaded to the MCU in order for the firmware to work.
2017-01-21 02:02:50 +01:00
László Monda
cad09faf02
Resolve USB reenumeration issue. Don't ask me why it's working now. We should find an explanation eventually.
2017-01-20 02:04:08 +01:00
László Monda
ece0ffc6fc
Control the left and right side PWM brightness via separate protocol messages.
2017-01-15 04:52:23 +01:00
László Monda
4137f919a2
Clean up the case BRIDGE_COMMAND_SET_TEST_LED clause of the bridge protocol handler.
2017-01-14 00:35:01 +01:00
László Monda
50443faa23
Don't blink the test LED anymore for the set PWM command.
2017-01-14 00:32:48 +01:00
László Monda
64eeb3a000
Make global LED PWM brightness adjustment work by enabling the TPM clock.
2017-01-14 00:30:40 +01:00
László Monda
1f4672e2f4
Clean up both LedPwm_Init() functions.
2017-01-13 23:32:37 +01:00
László Monda
24a12908ca
Call UpdateUsbReports() from the interrupt handler of the keyboard interface because otherwise the I2C calls of UpdateUsbReports run in the main loop and interfere with the I2C calls of interrupt handlers. This is a temporary solution.
2017-01-13 22:34:11 +01:00
László Monda
9ef9e5f734
Drive the LED_PWM line of the left half via TPM which doesn't work yet for some reason. Add protocol command for setting the LED_PWM brightness of the left half. Expose UpdateUsbReports()
2017-01-13 21:43:47 +01:00
László Monda
0ded50b43a
PWM the R_EXT of the LED driver using FTM.
2017-01-13 14:58:31 +01:00
László Monda
3348fb0848
Lowercase protocol handler functions according to our coding standards because they're not extern.
2017-01-10 01:30:46 +01:00
László Monda
a76a690a98
Rename UsbKeyboadTask() to updateUsbReports() and move it to main.c
2017-01-10 01:19:29 +01:00
László Monda
a0c7f407e8
Reset the USB keyboard report with a single bzero() call.
2017-01-10 01:07:51 +01:00
László Monda
736d4a621a
Create nice API for USB keyboard reports featuring ActiveUsbKeyboardReport, ResetActiveUsbKeyboardReport(), SwitchActiveUsbKeyboardReport()
2017-01-10 01:05:27 +01:00
László Monda
0f70d1eb8e
Resolve compiler warnings.
2017-01-09 20:39:25 +01:00
László Monda
a79a2c7365
Rename default_layout.c to current_keymap.c and add current_keymap.h
2017-01-09 20:25:35 +01:00
László Monda
f6a8c56f61
Enable the FET to drive LED_PWM at full blast.
2017-01-09 18:57:20 +01:00
László Monda
24cdab4be2
Enable only the existing LEDs via LED control registers rather than PWM registers.
2017-01-09 17:16:12 +01:00
László Monda
e12996d444
Light up every LED without screwing up I2C communication.
2017-01-09 15:00:57 +01:00
László Monda
c44d75f1bc
Enable as many LED rows as possible without interfering with I2C communication.
2017-01-09 02:40:20 +01:00
László Monda
74c965190c
Explicitly run the relevant build when starting debug configurations.
2017-01-07 18:39:10 +01:00
László Monda
1433b57a46
Add update config and apply config protocol commands.
2017-01-07 03:26:44 +01:00
László Monda
a74c6016f5
Disable LEDs by default because they make I2C communication unreliable on (at least) one prototype.
2017-01-06 22:48:43 +01:00
László Monda
5d1df4449e
Merge pull request #29 from algernon/f/deserialize
...
WIP: Initial deserialization code
2017-01-06 18:55:43 +01:00
László Monda
8c29c99ef4
Merge pull request #28 from algernon/f/key_action_t/updates
...
Minor key_action_t updates
2017-01-06 13:17:17 +01:00
Gergely Nagy
3c817f0b1b
deserialize: Initial layer deserialization
...
So far, the code is able to deserialize and apply a single layer, as saved by
the Agent in binary format. It does not support macros and keymap switching
yet (it parses the latter, but will choke on the former), but the rest should be
handled fine.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org >
2017-01-06 09:05:00 +01:00
Gergely Nagy
00214eac7e
action.h: Rename switchKeymap.layer to switchKeymap.keymap
...
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org >
2017-01-06 08:09:03 +01:00
Gergely Nagy
901814be2f
action.h: Add keystroke.longpress and switchLayer.isToggle
...
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org >
2017-01-06 08:09:03 +01:00
László Monda
f76d17279e
Change the merge sensor pin for the v7 PCB.
2017-01-05 21:02:28 +01:00
László Monda
fb79862cee
Clean up coding style a bit.
2017-01-05 19:29:08 +01:00
László Monda
ce1b16f406
Remove LED jumper and ISO jumper related code, as the presence of LEDs and ISO/ANSI configuration will be stored in the hardware configuration area of the EEPROM instead of using solder jumpers.
2017-01-05 19:25:39 +01:00
László Monda
a817118eb3
Change test LED pin for the v7 PCB.
2017-01-03 02:29:50 +01:00
László Monda
d1040653a1
Add build and debug configuration files for version 6 and version 7 of the left keyboard half.
2017-01-03 02:11:34 +01:00
László Monda
ec59922a23
Tweak module and layer comments a bit.
2017-01-03 01:46:45 +01:00
László Monda
e2b2f6c5a9
Rename key action fields.
2017-01-03 01:35:33 +01:00
László Monda
f09cc2d89c
Deduplicate the body of clearKeymasks() and rename it to clearKeymask()
2017-01-03 01:27:00 +01:00
László Monda
46891f6a7f
Deduplicate the memcpy() calls of HandleKeyboardEvents()
2017-01-03 01:22:04 +01:00
László Monda
c2e25b8007
Deduplicate the gist of HandleKeyboardEvents()
2017-01-03 01:20:20 +01:00
László Monda
2457f3b0e0
Add CurrentKeyStates and PreviousKeyStates globals and use them across the whole codebase.
2017-01-03 01:09:00 +01:00
László Monda
3942d089de
Rename keyMatrix to KeyMatrix because it's a global.
2017-01-02 23:11:24 +01:00
László Monda
c1a6eaffde
Don't inline getKeycode(). Do some coding style fixes.
2017-01-02 23:09:22 +01:00
László Monda
47c7863026
Move keyMatrix to main.c and only initialize it once in main()
2017-01-02 22:55:23 +01:00
László Monda
64ca3001de
Merge readLeft() into UsbKeyboardTask()
2017-01-02 22:16:08 +01:00
László Monda
0c404f324d
Rename a couple of key action related type names and enum values.
2017-01-02 21:25:38 +01:00
László Monda
cda497e5ac
Write key instead of k.
2017-01-02 21:14:44 +01:00
László Monda
38245d9749
Zero the content of GenericHidOutBuffer before processing protocol commands.
2017-01-02 21:09:11 +01:00