config.h (1747B)
1 /* 2 Copyright 2012 Jun Wako <wakojun@gmail.com> 3 4 This program is free software: you can redistribute it and/or modify 5 it under the terms of the GNU General Public License as published by 6 the Free Software Foundation, either version 2 of the License, or 7 (at your option) any later version. 8 9 This program is distributed in the hope that it will be useful, 10 but WITHOUT ANY WARRANTY; without even the implied warranty of 11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 GNU General Public License for more details. 13 14 You should have received a copy of the GNU General Public License 15 along with this program. If not, see <http://www.gnu.org/licenses/>. 16 */ 17 18 /* This code makes use of cy384's Arduino USB HID adapter for the Palm Portable 19 Keyboard, released under the BSD licence */ 20 21 22 23 24 #pragma once 25 26 // IO pins to serial 27 // https://deskthority.net/wiki/Arduino_Pro_Micro for pin lookup 28 #define VCC_PIN D1 // pro micro 2 29 #define RX_PIN D0 //pro micro 3 , was 8 on cy384 30 #define RTS_PIN C6 // 5 //[ was D4 // 4 on the cy384 31 #define DCD_PIN E6 //7 32 33 // if using the particular arduino pinout of CY384 34 #ifdef CY384 35 #define GND_PIN D7 //6 36 #define PULLDOWN_PIN B1 // 15 37 #endif 38 39 #ifndef HANDSPRING 40 // Set to 1 for Handspring or to disable RTS/DCD based handshake. 41 #define HANDSPRING 0 42 #endif 43 44 #define MAXDROP 10 // check if keyboard is connected every X polling cycles 45 #define SLEEP_TIMEOUT 500000 // check keyboard/reset this many millis 46 47 48 #define MATRIX_ROWS 12 49 #define MATRIX_COLS 8 50 51 /* key combination for command */ 52 #define IS_COMMAND() ( \ 53 get_mods() == (MOD_BIT(KC_LALT) | MOD_BIT(KC_RALT)) || \ 54 get_mods() == (MOD_BIT(KC_LGUI) | MOD_BIT(KC_RGUI)) || \ 55 get_mods() == (MOD_BIT(KC_LSFT) | MOD_BIT(KC_RSFT)) \ 56 )