library ieee; use ieee.std_logic_1164.all; use ieee.numeric_std.all; entity phonybench is generic ( GENSTR : string := "adrien"; GENSTDLV : std_logic_vector(5 downto 0) := "111000"; GENSTDL : std_logic := '1'; GENNAT : natural := 22 ); end phonybench; architecture bench of phonybench is type char2std_t is array(character) of std_ulogic; constant char2std_c : char2std_t := ( 'U' => 'U', 'X' => 'X', '0' => '0', '1' => '1', 'Z' => 'Z', 'W' => 'W', 'L' => 'L', 'H' => 'H', '-' => '-', others => 'X' ); function str2std(arg : string) return std_logic_vector is variable result : std_logic_vector(arg'length - 1 downto 0); variable j : integer; begin j := arg'length - 1; for i in arg'range loop result(j) := char2std_c(arg(i)); j := j - 1; end loop; return result; end function; signal sigvec1 : std_logic_vector(5 downto 0) := str2std(GENSTR); signal sigvec2 : std_logic_vector(5 downto 0) := GENSTDLV; signal siglog : std_logic := GENSTDL; signal signat : natural := GENNAT; signal clk : std_logic := '0'; begin clk <= not clk after 5 ms; sigvec1 <= str2std(GENSTR); sigvec2 <= GENSTDLV; siglog <= GENSTDL; signat <= GENNAT; end architecture; '> aboutsummaryrefslogtreecommitdiffstats
path: root/quantum/process_keycode/process_key_lock.h
blob: a8e110a4bf93d408e74ac318d6a71cc6a15ed790 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/* Copyright 2017 Fredric Silberberg
 *
 * 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.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef PROCESS_KEY_LOCK_H
#define PROCESS_KEY_LOCK_H

#include "quantum.h"

bool process_key_lock(uint16_t *keycode, keyrecord_t *record);

#endif  // PROCESS_KEY_LOCK_H