From 221901e98c71fe1b4d8bf781f2f549862bb64239 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ebbe=20Ba=C3=9F?= Date: Fri, 22 Apr 2022 19:00:31 +0200 Subject: [PATCH] Added all files MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Ebbe Baß --- .gitignore | 7 +++++-- boot.py | 16 ++++++++++++++++ code.py | 1 + lib/adafruit_hid/__init__.mpy | Bin 0 -> 441 bytes lib/adafruit_hid/consumer_control.mpy | Bin 0 -> 1041 bytes lib/adafruit_hid/consumer_control_code.mpy | Bin 0 -> 482 bytes lib/adafruit_hid/gamepad.mpy | Bin 0 -> 2561 bytes lib/adafruit_hid/keyboard.mpy | Bin 0 -> 1957 bytes lib/adafruit_hid/keyboard_layout_us.mpy | Bin 0 -> 1305 bytes lib/adafruit_hid/keycode.mpy | Bin 0 -> 2176 bytes lib/adafruit_hid/mouse.mpy | Bin 0 -> 1605 bytes 11 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 boot.py create mode 100644 code.py create mode 100644 lib/adafruit_hid/__init__.mpy create mode 100644 lib/adafruit_hid/consumer_control.mpy create mode 100644 lib/adafruit_hid/consumer_control_code.mpy create mode 100644 lib/adafruit_hid/gamepad.mpy create mode 100644 lib/adafruit_hid/keyboard.mpy create mode 100644 lib/adafruit_hid/keyboard_layout_us.mpy create mode 100644 lib/adafruit_hid/keycode.mpy create mode 100644 lib/adafruit_hid/mouse.mpy diff --git a/.gitignore b/.gitignore index f8b73e7..d5024ff 100644 --- a/.gitignore +++ b/.gitignore @@ -15,8 +15,6 @@ dist/ downloads/ eggs/ .eggs/ -lib/ -lib64/ parts/ sdist/ var/ @@ -138,3 +136,8 @@ dmypy.json # Cython debug symbols cython_debug/ +boot_out.txt +.metadata_never_index +/System Volume Information +.fseventsd +.Trashes diff --git a/boot.py b/boot.py new file mode 100644 index 0000000..dbf2b1e --- /dev/null +++ b/boot.py @@ -0,0 +1,16 @@ +from board import * +import digitalio +import storage + +noStorageStatus = False +noStoragePin = digitalio.DigitalInOut(GP15) +noStoragePin.switch_to_input(pull=digitalio.Pull.UP) +noStorageStatus = not noStoragePin.value + +if(noStorageStatus == True): + # don't show USB drive to host PC + storage.disable_usb_drive() + print("Disabling USB drive") +else: + # normal boot + print("USB drive enabled") diff --git a/code.py b/code.py new file mode 100644 index 0000000..f301245 --- /dev/null +++ b/code.py @@ -0,0 +1 @@ +print("Hello World!") diff --git a/lib/adafruit_hid/__init__.mpy b/lib/adafruit_hid/__init__.mpy new file mode 100644 index 0000000000000000000000000000000000000000..29daa942e607fe56408fae27f4a84cccb5fee80f GIT binary patch literal 441 zcmZ`#!AiqG5Zz5%EQTKHp%G~@wQ02o34$e1M3gEjBIw0Sg>}ttn}s$ByPHZ+#y_eC zJPUqB{Tba_DvCIVVTO6UdGB3hwDkrAvnsft3bC0K8x(+#QVm)g&;XVNZ=qF(#cqCY z7?OBE_g68&JsvZOd`29ESfEB^N8{YCy<@j@ghrGL76u6A5#lro5z>1sAc)Wr^C*O( z?MoSnw&V1f^y53*3y02v)j3?ycNq87o6E8E71`<8k*(le9RR3-l{&1#$F+lPt6?^q z=XE8y`~oIMhG=d!nOwow$w{XM-qOk@e44tYB&}@0=c!vr6f8Be3Z^A#xAp!|z6VB* zz#C=pr^zQ;@(fs-dlrAtLKjp;GK+`H-%G6% Z#sgvop)_Z)nL{i+p9OtWMPSbP>`%4LjKTl_ literal 0 HcmV?d00001 diff --git a/lib/adafruit_hid/consumer_control.mpy b/lib/adafruit_hid/consumer_control.mpy new file mode 100644 index 0000000000000000000000000000000000000000..ff510dceb3d45625c010d866136dd1e53b2ab1b5 GIT binary patch literal 1041 zcma))&2G~`5XWcIv`If`i9o4nldwtMB%+W8OI0rwA1al~0a2;qRHTiG*Ti6Z&8}UD z5RwDs29JW2J`G2XyhJ5f+esCLL$TzUSzJVQSPw4;gM$3 z2lx{edNtH)xL(8Z29`C9s$YKY7NYeItU~1ntk=Lo6JMg*xQW_k?CYr2aZqgF5%v)5 z25Jq|Ne7EfG&5Qg3n%$Kmz$x(9uUJcED_oP?b+sbmwPgFnV>2N1b13~e@6D@_+7SL z-(fEE0wb`wmpf%bD!=&D^|=TRgy3S%;=(n8Jf)uDGD_!UAi{1ia@oLkSz;C~+cT-j zPVFv($;D*6vOlUv`M8|vHKNo%wm%VD5|0N&hJIWJGl}hyeOq)D)=@v`agXS&4}=Ti z@b^q?VIuZY6RY_B)}yaCmC8y*tqMvXtqvW~)}Vvh1r$!EZ@f~jOYj9sQ;8{^{>c)h z??S^#1yToWPsvZSl6fX%tUN*nps=P!VNmLHB5#c1YANIq++DHPTCUtZd^zeIBO|b})LZ24H;cl|+*bSqP=^ zno(bw*(AIkPf9v6X)otr^#f)IVf1rUu(%xwSMK?7G9F3qXQjiKpYnooj+ILf%i}!6 z@XHr5d^=jvTdkOU6Dz-=cpr!57Dne*Rv(tPu%ahxg%-7wL?gBXWhZlmljNQ&DMtf3 n?;G8>sv!Z->>Z8?{()SKTQ$NPZ<_Z1bqG@YYnLK+xyk+le11or literal 0 HcmV?d00001 diff --git a/lib/adafruit_hid/consumer_control_code.mpy b/lib/adafruit_hid/consumer_control_code.mpy new file mode 100644 index 0000000000000000000000000000000000000000..b6fc457ae0220da0543a11e6c4a742bdb31aff26 GIT binary patch literal 482 zcma)&TTj9;6o6Ymvmizd#1|hJvk)}~B3|&pm@HjMP%lFmv!3uEjYUGij3)dVzXnneN%uTxD=+ayg$*hegz>v DO4NtP literal 0 HcmV?d00001 diff --git a/lib/adafruit_hid/gamepad.mpy b/lib/adafruit_hid/gamepad.mpy new file mode 100644 index 0000000000000000000000000000000000000000..54f4a2502644a1cbc210898a73343fb047e8e416 GIT binary patch literal 2561 zcmcImTTdHD6rKaVVgq$RhJtYxSWFTE*ydtxZ36@)sniCk7geRw?81)0WPR!Gn#8=Y zu0o|st<;A;^;eiAzaT%MeT%BLYAf}zQvX1DW-k~!*(QDHSUZ<90M ze(;vPkJ}Qc`7FpI6EF(jTr$I_lT5OHH@;4shQI1Rl<)+@V?-R~AjK4sh&V(f5a&Va z5SKyf6jwm zXesTY)aHaz_diieKd;KFJ&y|uCFF^AS2U*Ubhm04<&xg3F_p1KP^>@yG(0Y zG}v6^?#eAyM!M>;5ReW+hKEoq^@JqpX7Err6eh4RVf@2uNP9wrv-nli%QZMv9zr8^ z1riU*mkRc#&U@FvY^0`nHN&e}UZr`Jfp;RLk<3D#WN$89Hq!}}{E~~C*~B;`=b)a4 ztTVf{0OmSM&*jm}BNvs_Rn_HvMk`qPt!^)MH0o$DyjwGvtZ8yBNHta|Yev%&rK+qO zj=9IBpK^X#fIEObu$!9Q9EU8UMvt353Eur+OVi4lC4RrIGFE9$65`XDnh)CHps#cj z079bkDDwKIkXk}=&u(qLNuD;+BhyfCBy;d65B0zQ`gIPuT=?UpkzC@u#dcaX<;6_f z8N9^Nw#=55gLT!xxXdx$5mL)G#-SH6{_vXx^7kglcB%i5Fa=C;NM&S&!@PTA0#TyY zrs15hmxbAD;%VU{6|j63S>-SKNVtkGY9#03Y;d2TZkO#2`lls=yc#6>)jQ zH{eqK3m#O>K=nF!TcrGZQm`=wWc9vW(;a83QG)3e`j$Ar6Y0*Dh-E+hJ~}fo2FX83 zd=nZYQiCz+U;E|ZeILPXKhKH?hfs_H^Q$gC%w9B+_q%{hb)J>S^O5@ zv7O_beV64SS8t@}pDp{%Z=Wr6m~+|1u$j0|20($&pt0kX=DdjL`k3E+R@Md*aIWd` z4ePoV?CVn~R&_%tlmtyK?K2@G7-b=|IOhOc=fJ*S~jIT1K_ literal 0 HcmV?d00001 diff --git a/lib/adafruit_hid/keyboard.mpy b/lib/adafruit_hid/keyboard.mpy new file mode 100644 index 0000000000000000000000000000000000000000..6fe3aceda112f8b8b7c8dc867ff1dbbeb6fba1f7 GIT binary patch literal 1957 zcmcJPTW=ai6vyY_3j}Cw9!xA7%ODG%Xcu4kEZe&>JA7gMp- zTT@8<=Buaxy2Rq|?C-ZfLFjLmX{>>~1}uAu_M!1BGEb3wij;m<2EM-lrVO$Sd|woM zKxPr-A}ErEvSl!0av3s*i4R-0(P@&87Ij0f(~jxlhG|^6L%K({PL0iWciJ^u#2aR6 zw&l2~mRX~AyX!V=%RlkQ_#WxjY=gx4x85A?gE>_hJo++WUy;vO4>Gcm-*bXPssSDPVH83hvNNo0#FR0g(aT({<5Yy-^Zy$ zr3(k^Jnmc(M%fMMXD`8h;~or4>yW#L9vFOe8FE)(xN;c`VEwORg<)y)-;-}M-bn>M zPN89b3+hO@s;;t1u8DrDW|@*(gS-O$Iw-;IH5J&W99tM_B(}*!COeLPOmLeIGv0Du z#OS3q(7?H)u1j=E_3o?>BiZ6CX!pbkH|<7$j$4mp|ok9Pj-DNJ1)-?7Klb8O_< zl|z%KJtcP+osSuCi#M(aMMVY^cI0$eKlsRWU#uw}>tqG}?>c!?Z+3`RP!Lp3(8`>R z1KKsMW68B8uLDZFgo)%fbW3u~ZzNHdlI}{jRU?}>eS~wn0^xTYq3tPp65iYx-Y-u% jy#l9~9TVd8;*1+`l0sY@;qN_Ohp*D}n_&~Sj{w3y%dB}Q literal 0 HcmV?d00001 diff --git a/lib/adafruit_hid/keyboard_layout_us.mpy b/lib/adafruit_hid/keyboard_layout_us.mpy new file mode 100644 index 0000000000000000000000000000000000000000..89f085645635af1e96f7743ff5600b8d981bfc0f GIT binary patch literal 1305 zcmbtT$xjne7=N!Vw6q{C0%d7o+76|aQYwly#uyP<8W5U*CZ;B@4`wQjLkDMC2`8t< zy5qj@E1uLYZizRzc;=)>O}z3i;LLQ2)m})P!+gto?|Z-B?|t6^wW`&p2GUpQ2R4Wa zK|2e;TC&~&gK*joqYg+qU^fv4^(3TJBneF+-R>EdN-*>uJEm}iOGM*nI!bjNqvt1C z%u$HJ^K2rH61;bIUOPQap&(q=m#Z4x-r32KvoY=dS%I$;=+O(3iy-7u^seK4#cJtFdw;u~O~Lnwx4 zXoU0#<#{7iQl}E3;|a_t8^?zN0~2Uqq<7HRJKh%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{joHitY5894PEMvveoF<&Bn>tz_8Hvs%2`5*an7 zr*$pdm(^`in=s{m;mENVPbeJIGa0$k5T>ff>lEG0$!6TKO3~FkHOoosu~blL4k|4{ zr8TIu1(o)o(h*cTgGyIW=?*E)O>E6Gy%8(Pn$r_b$kruWH37)3wit9P8#(NyuH1*sn_c=XT>T_Hf$r_$`BP9k6IqqoL zOlhK0xw-5)-Yh$1iENfJio!)9&Nma35kzv;n@iLLNmqbWT+a;^ijnZ^H zeac*L!P|JIH za(uFQ$QhlS3s74)5a4fh%@h7kUtZr+&maG%YZmEQQ`__I$imY#kLh`PaG|xOGqP~x i8NZnR`FnU_c-a`Qdw(ojqL*_C1VUp|vsLAP5B~y{x)&_~ literal 0 HcmV?d00001 diff --git a/lib/adafruit_hid/mouse.mpy b/lib/adafruit_hid/mouse.mpy new file mode 100644 index 0000000000000000000000000000000000000000..6289bd4697bdcf041d3f88a41d86869d8d0cdea3 GIT binary patch literal 1605 zcmbVLNmCO+80{}B5MmicN-@Ncv`mU<#7Lx|Tu{NK3S9BTp=Zo=%;-!KXC?@z%pf^f zmIu$CJb6t(xx4-V&z4#qIQkc~XNe|MJm{pVznYkoB(q$3D=w_b*ugb4CQJ!zzYh1fK4m!EyGRsqe2x>b-QP zzURqkJ;-PtOdvdBF~XzB#D`%GkHR|UfJb-;@qovH_uwq>UVH+0AD#fiFs^&|3x1pf zK7ccDuow8C2zZ*waiF_v=^>;fD3p*sLLAYAIQ#nvc~BK(XEiiGcX5%NzrDD4?P~wc zE0->}Ucw7kW@qQ;+$DCJRASvC{)$R9EvQnN3K|W$l?bxz&&yK&zE3GH(=gE}YhS6% zke6w{rVF~1SEybrivc1_iln2SLJuGhLVJgpiRKW`Ykd4(Jh?c=dK67Ub1==EJOXRt zIy6SdAi9p$MK(JMXG5qF%Rm8TXLE;)@u-ZxP7WH`XaZu#z$`%4U7gE;agI6OBHq1A z?RNH6HQ_EL6*lrny|b!QK~;s-fJ!T6Rqs?8ymo6&Rm-X!AHOD3TIt+? zkWZs>A?Sok;{wRi-#^acVrGqSnh9?V9|hz1Nb}nS=c-^H+YRr|zAKRy&Yh~RmrGj8 z#mQPY7xz98?uoOOQQIFL-GQt5O$gE0fj-7*@nX$#}M zRW}Oo!K#}D`1oqTto^W*n%wKwbdB3;O&@WM;W3Dv25SqW+I+SBX5;nt+s&=*cTMB- z$(OYaHomBBvhjH>vSi<(?)=^Bv!gh9bkp!V6z$;+*%z{7pDP|#VAcPyNU1#K*cZ-N z>L15B?ze#^XZyJ3l$~-SOPxXg3-b=}e-NC(zRPrjq3ezk~n*Ixy