Advertisement
Guest User

Untitled

a guest
May 22nd, 2015
216
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 6.37 KB | None | 0 0
  1. /*
  2. LICENSING INFORMATION
  3.  
  4. The firmware, known as an "arduino sketch" with the file extension .ino contained within this bundle contains firmware for the UniqueK Diverge Keyboard written by Blahlicus,
  5.  
  6. this firmware is under a slightly modified version of the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0) license, this means any
  7.  
  8. individual who downloaded this piece of binary data must give appropriate credit to the original creator of this piece of software, this software is also non-commercial,
  9.  
  10. anyone except for the original creator may not use this piece of code commercially and this software is also a non-derivatives work, this means, you ARE ALLOWED to remix,
  11.  
  12. transform, or build upon the material, however, if you remix, transform, or build upon the material, you may not distribute the modified material. for more information about this license, you may visit the following website:
  13.  
  14. http://creativecommons.org/licenses/by-nc-nd/4.0/
  15.  
  16. furthermore, this piece of software is provided to you "as is." and the creator of this bundle (Blahlicus) make no express or
  17.  
  18. implied warrenties whatsoever with respect to its functionality, operability, or use, including, without limitation, any implied warrenties of merchantability, fitness for a
  19.  
  20. particular purpose, or infringement. the creator (Blahlicus) expressly disclaim any liability whatsoever for any diret, indirect, consequential, incidential and/or special
  21.  
  22. damages, including, without limitation, lost revenues, lost profits, losses resulting from business interruption or loss of data, lost of functionality of devices including
  23.  
  24. but not limited to any devices made by the unincorporated company known as "UniqueK" or "Unique Keyboard," regardless of the form of action or legal theory under which the
  25.  
  26. liability may be asserted, even if advised of the possibility or likelihood of such damages.
  27.  
  28. INTRODUCTION
  29.  
  30. hey guys, blahlicus here, this file contains the array definition for the keys on the keyboard, the key names themselves should be self explanatory enough, for references to key names, you may check out the keydeclaration.ino file
  31.  
  32. to edit the delay rates, you may edit the bRate value for baud rate and rDelay value for refresh delay (in milliseconds)
  33.  
  34. */
  35.  
  36. void inilayout()
  37. {
  38.   bRate = 9600;
  39.  
  40.   rDelay = 10;
  41.  
  42.  
  43.   // array is here
  44. keyLayout[0][0][0] = ktab;
  45. keyLayout[0][0][1] = kesc;
  46. keyLayout[0][0][2] = kf1;
  47. keyLayout[0][1][0] = kcaps;
  48. keyLayout[0][1][1] = kcaps;
  49. keyLayout[0][1][2] = k1;
  50. keyLayout[0][2][0] = klshift;
  51. keyLayout[0][2][1] = klshift;
  52. keyLayout[0][2][2] = klshift;
  53. keyLayout[0][3][0] = klctrl;
  54. keyLayout[0][3][1] = klctrl;
  55. keyLayout[0][3][2] = klctrl;
  56. keyLayout[1][0][0] = kq;
  57. keyLayout[1][0][1] = kq;
  58. keyLayout[1][0][2] = kf2;
  59. keyLayout[1][1][0] = ka;
  60. keyLayout[1][1][1] = klarrow;
  61. keyLayout[1][1][2] = k2;
  62. keyLayout[1][2][0] = kz;
  63. keyLayout[1][2][1] = kmediaprevious;
  64. keyLayout[1][2][2] = kz;
  65. keyLayout[1][3][0] = klwin;
  66. keyLayout[1][3][1] = klwin;
  67. keyLayout[1][3][2] = klwin;
  68. keyLayout[2][0][0] = kw;
  69. keyLayout[2][0][1] = kuarrow;
  70. keyLayout[2][0][2] = kf3;
  71. keyLayout[2][1][0] = ks;
  72. keyLayout[2][1][1] = kdarrow;
  73. keyLayout[2][1][2] = k3;
  74. keyLayout[2][2][0] = kx;
  75. keyLayout[2][2][1] = kmediaplay;
  76. keyLayout[2][2][2] = kx;
  77. keyLayout[2][3][0] = kfn;
  78. keyLayout[2][3][1] = kfn;
  79. keyLayout[2][3][2] = kfn;
  80. keyLayout[3][0][0] = ke;
  81. keyLayout[3][0][1] = ke;
  82. keyLayout[3][0][2] = kf4;
  83. keyLayout[3][1][0] = kd;
  84. keyLayout[3][1][1] = krarrow;
  85. keyLayout[3][1][2] = k4;
  86. keyLayout[3][2][0] = kc;
  87. keyLayout[3][2][1] = kmediapause;
  88. keyLayout[3][2][2] = kc;
  89. keyLayout[3][3][0] = klalt;
  90. keyLayout[3][3][1] = klalt;
  91. keyLayout[3][3][2] = klalt;
  92. keyLayout[4][0][0] = kr;
  93. keyLayout[4][0][1] = kr;
  94. keyLayout[4][0][2] = kf5;
  95. keyLayout[4][1][0] = kf;
  96. keyLayout[4][1][1] = kf;
  97. keyLayout[4][1][2] = k5;
  98. keyLayout[4][2][0] = kv;
  99. keyLayout[4][2][1] = kmedianext;
  100. keyLayout[4][2][2] = kv;
  101. keyLayout[4][3][0] = kspace;
  102. keyLayout[4][3][1] = kspace;
  103. keyLayout[4][3][2] = kspace;
  104. keyLayout[5][0][0] = kt;
  105. keyLayout[5][0][1] = kt;
  106. keyLayout[5][0][2] = kf6;
  107. keyLayout[5][1][0] = kg;
  108. keyLayout[5][1][1] = kg;
  109. keyLayout[5][1][2] = k6;
  110. keyLayout[5][2][0] = kb;
  111. keyLayout[5][2][1] = kb;
  112. keyLayout[5][2][2] = kb;
  113. keyLayout[5][3][0] = knull;
  114. keyLayout[5][3][1] = knull;
  115. keyLayout[5][3][2] = knull;
  116. keyLayout[6][0][0] = ky;
  117. keyLayout[6][0][1] = ky;
  118. keyLayout[6][0][2] = kf7;
  119. keyLayout[6][1][0] = kh;
  120. keyLayout[6][1][1] = kh;
  121. keyLayout[6][1][2] = k7;
  122. keyLayout[6][2][0] = kw;
  123. keyLayout[6][2][1] = kw;
  124. keyLayout[6][2][2] = kw;
  125. keyLayout[6][3][0] = kspacepm;
  126. keyLayout[6][3][1] = kspacepm;
  127. keyLayout[6][3][2] = kspacepm;
  128. keyLayout[7][0][0] = ku;
  129. keyLayout[7][0][1] = ku;
  130. keyLayout[7][0][2] = kf8;
  131. keyLayout[7][1][0] = kj;
  132. keyLayout[7][1][1] = kj;
  133. keyLayout[7][1][2] = k8;
  134. keyLayout[7][2][0] = km;
  135. keyLayout[7][2][1] = km;
  136. keyLayout[7][2][2] = km;
  137. keyLayout[7][3][0] = knull;
  138. keyLayout[7][3][1] = knull;
  139. keyLayout[7][3][2] = knull;
  140. keyLayout[8][0][0] = ki;
  141. keyLayout[8][0][1] = ki;
  142. keyLayout[8][0][2] = kf9;
  143. keyLayout[8][1][0] = kk;
  144. keyLayout[8][1][1] = kk;
  145. keyLayout[8][1][2] = k9;
  146. keyLayout[8][2][0] = kcomma;
  147. keyLayout[8][2][1] = kcomma;
  148. keyLayout[8][2][2] = kcomma;
  149. keyLayout[8][3][0] = kralt;
  150. keyLayout[8][3][1] = kralt;
  151. keyLayout[8][3][2] = kralt;
  152. keyLayout[9][0][0] = ko;
  153. keyLayout[9][0][1] = klbracket;
  154. keyLayout[9][0][2] = kf10;
  155. keyLayout[9][1][0] = kl;
  156. keyLayout[9][1][1] = ksemicolon;
  157. keyLayout[9][1][2] = k0;
  158. keyLayout[9][2][0] = kperiod;
  159. keyLayout[9][2][1] = kperiod;
  160. keyLayout[9][2][2] = kperiod;
  161. keyLayout[9][3][0] = kanimus;
  162. keyLayout[9][3][1] = kanimus;
  163. keyLayout[9][3][2] = kanimus;
  164. keyLayout[10][0][0] = kp;
  165. keyLayout[10][0][1] = krbracket;
  166. keyLayout[10][0][2] = kf11;
  167. keyLayout[10][1][0] = ksemicolon;
  168. keyLayout[10][1][1] = kapostrophe;
  169. keyLayout[10][1][2] = khyphen;
  170. keyLayout[10][2][0] = kslash;
  171. keyLayout[10][2][1] = kslash;
  172. keyLayout[10][2][2] = kslash;
  173. keyLayout[10][3][0] = krwin;
  174. keyLayout[10][3][1] = krwin;
  175. keyLayout[10][3][2] = krwin;
  176. keyLayout[11][0][0] = kbkspace;
  177. keyLayout[11][0][1] = kbkspace;
  178. keyLayout[11][0][2] = kf12;
  179. keyLayout[11][1][0] = kenter;
  180. keyLayout[11][1][1] = kenter;
  181. keyLayout[11][1][2] = kequals;
  182. keyLayout[11][2][0] = krshift;
  183. keyLayout[11][2][1] = krshift;
  184. keyLayout[11][2][2] = krshift;
  185. keyLayout[11][3][0] = krctrl;
  186. keyLayout[11][3][1] = krctrl;
  187. keyLayout[11][3][2] = krctrl;
  188.  
  189.  
  190.  
  191.  
  192. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement