Contains the source code from the course work throughout my undergraduate Computer Engineering degree at Brigham Young University. There is a mixture of Go, Python, C, C++, Java, VHDL, Verilog, Matlab, Bash, Assembly, etc..
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

shoot.c 14KB

123
  1. int shoot_soundData[] = {127,99,103,92,42,127,31,105,52,118,55,92,116,31,104,61,84,102,72,101,75,127,47,121,47,94,125,49,90,72,79,121,61,118,68,122,51,120,64,106,113,83,105,54,122,56,123,74,106,41,20,91,43,84,93,115,34,81,106,47,72,58,65,113,95,12,0,79,89,111,120,18,1,1,118,0,0,0,0,0,89,20,1,1,1,1,66,0,0,0,20,86,95,119,1,1,1,75,37,0,0,15,0,60,89,1,1,1,1,1,60,0,0,41,60,44,128,45,1,1,1,106,51,12,0,0,10,120,55,48,20,1,1,47,0,0,0,15,16,31,128,1,1,1,1,4,112,0,0,0,77,68,75,85,1,1,1,23,117,53,0,0,9,106,77,123,47,1,1,1,110,68,7,0,0,0,120,90,97,37,1,1,1,82,0,0,0,0,0,81,42,31,27,1,1,1,115,0,0,0,75,63,47,126,47,1,1,1,34,119,54,0,0,0,112,123,103,71,1,1,1,34,120,74,0,0,0,102,96,98,79,1,1,1,1,65,119,0,0,0,44,125,116,122,34,1,1,1,20,98,50,0,0,0,17,127,48,92,62,1,1,1,58,19,0,0,0,0,40,102,51,65,47,1,1,1,109,74,20,0,0,0,112,116,119,76,1,1,1,20,45,122,0,0,0,33,85,81,123,49,1,1,1,1,1,124,0,0,0,29,31,33,115,72,1,1,8,1,1,30,33,0,0,0,55,44,58,128,41,1,13,1,1,1,30,36,0,0,0,12,31,98,86,24,31,28,1,1,1,116,39,0,0,0,0,13,96,64,64,82,14,1,1,1,49,50,0,0,0,0,0,70,107,24,64,65,8,1,1,20,116,40,0,0,0,0,24,118,48,89,93,32,1,1,1,47,119,63,10,0,0,0,88,120,115,103,75,3,1,1,28,17,37,87,0,0,0,0,22,54,126,52,56,79,18,1,1,25,48,119,75,0,0,0,0,94,105,112,78,31,52,41,1,1,1,55,112,44,10,0,0,0,91,101,115,89,42,11,24,40,1,1,31,106,63,23,0,0,0,40,101,113,116,58,40,58,37,1,1,23,76,119,81,17,0,0,0,64,78,108,102,59,16,44,49,23,1,1,47,112,71,36,0,0,0,22,103,106,120,86,56,8,35,44,23,1,1,61,112,37,6,0,0,0,27,126,128,117,83,66,32,13,35,42,23,1,35,112,54,2,0,0,0,0,67,102,79,95,83,85,42,6,35,45,31,13,52,122,48,9,3,0,0,2,75,102,89,96,79,54,38,61,61,35,7,21,68,113,105,53,0,0,0,15,63,79,123,90,54,41,82,96,65,16,27,51,56,49,52,109,20,0,0,0,0,19,89,92,82,93,88,69,40,73,85,54,45,16,44,85,102,113,68,0,0,0,0,16,54,115,104,56,42,78,99,80,55,64,79,61,38,48,88,120,87,55,2,0,0,0,55,77,108,104,76,45,58,90,86,69,61,75,71,51,38,82,107,124,91,60,0,0,0,3,64,88,108,97,58,59,75,89,79,62,83,97,72,66,42,54,96,103,116,103,34,0,0,3,6,19,71,115,90,52,72,86,73,59,90,112,104,76,52,62,82,76,71,99,124,96,60,36,0,0,0,24,78,105,125,100,71,54,79,88,88,75,86,114,102,76,55,75,89,88,85,86,128,85,44,30,16,0,3,22,58,120,119,107,83,80,62,71,92,100,100,86,110,120,95,71,65,85,100,93,88,114,108,84,60,17,0,7,29,48,55,85,128,85,73,85,78,69,78,96,109,104,96,110,123,107,88,68,86,102,97,97,100,126,109,96,68,23,5,13,23,50,71,81,106,110,88,68,65,83,85,88,82,95,117,117,109,112,124,114,97,80,82,96,103,106,109,106,128,109,91,53,44,34,15,24,40,70,82,96,126,107,76,72,78,83,82,79,90,112,112,107,106,119,126,127,113,107,103,100,93,88,107,117,120,121,120,118,106,92,74,46,26,31,44,55,60,75,91,119,110,100,90,83,73,73,88,95,97,97,100,114,117,113,113,124,128,126,117,112,119,113,104,93,96,109,116,123,120,127,116,112,118,112,89,68,50,46,53,53,58,67,84,105,105,113,120,100,86,85,83,80,79,89,96,103,103,104,116,117,114,116,116,126,124,127,119,123,128,128,121,116,114,113,109,106,110,120,126,127,126,128,116,111,113,120,119,87,46,13,0,6,53,96,117,95,56,1,1,82,82,58,55,105,37,48,82,71,70,112,21,52,79,70,71,120,17,49,79,68,67,118,14,52,78,65,65,112,14,49,78,64,60,109,13,45,77,58,57,103,11,40,81,60,58,99,24,31,82,53,58,88,35,20,98,53,58,81,51,6,118,51,55,72,73,1,117,51,57,63,89,1,92,55,54,57,113,1,65,58,53,55,115,1,42,75,51,55,96,24,13,96,44,54,78,56,1,123,47,57,63,93,1,79,53,55,55,122,1,41,64,47,51,98,18,11,98,46,60,75,65,1,106,46,53,55,114,1,55,58,48,50,101,13,13,91,44,51,70,66,1,104,46,54,58,127,1,44,68,43,50,92,34,1,116,43,54,61,92,1,69,51,46,53,102,8,10,94,41,54,65,80,1,82,48,46,54,113,1,20,81,40,54,72,79,1,88,47,48,58,111,4,11,89,46,51,71,80,1,76,50,46,54,101,21,1,106,41,54,64,104,1,49,63,39,51,88,54,1,116,40,48,55,120,1,16,82,40,53,68,93,1,65,51,46,50,94,42,1,120,40,53,57,120,1,14,88,41,54,70,100,1,49,60,43,53,85,66,1,90,46,47,60,101,34,1,125,41,48,61,122,1,13,95,37,51,70,112,1,35,67,41,54,75,92,1,56,55,43,53,84,72,1,79,50,46,57,95,55,1,100,47,47,60,101,40,1,117,44,50,61,112,32,1,126,44,51,65,113,27,1,122,39,48,63,115,20,1,120,47,48,64,119,25,1,118,43,50,68,116,27,1,128,46,47,67,112,37,1,121,47,53,63,108,51,1,102,50,48,61,98,64,1,86,50,50,58,92,83,1,61,57,39,46,77,107,1,48,65,34,51,78,119,1,23,79,41,50,72,120,24,1,112,43,47,67,106,55,1,96,47,47,60,92,86,1,56,63,46,55,82,114,1,14,91,48,50,75,118,44,1,110,48,47,63,101,89,1,55,64,47,57,84,120,13,3,106,44,55,71,111,68,1,79,55,47,55,91,110,4,13,92,47,54,77,113,65,1,88,54,48,63,92,112,6,13,96,51,50,74,106,72,1,71,57,48,54,87,123,23,1,116,50,51,65,105,92,1,42,67,48,53,84,118,56,1,96,55,51,58,95,116,14,4,108,48,51,67,101,97,1,40,71,50,50,81,113,76,1,69,57,47,53,88,122,51,1,103,50,48,61,96,121,30,1,123,51,53,65,98,112,14,16,102,48,48,72,103,110,1,24,84,50,53,74,103,100,1,34,84,51,54,79,106,97,1,32,78,53,54,75,106,102,1,30,85,51,54,75,105,104,1,28,89,51,54,74,106,109,11,18,106,50,50,74,103,117,25,6,126,53,53,65,101,127,48,1,109,54,53,61,91,120,65,1,79,61,47,57,87,115,92,1,45,71,54,53,78,109,110,13,16,108,55,55,65,105,128,54,1,100,58,51,58,98,115,85,1,48,74,51,53,79,112,113,28,3,128,55,51,64,102,122,75,1,61,67,48,57,89,111,113,23,7,123,58,55,68,102,119,80,1,61,72,51,58,84,112,120,40,1,106,55,51,60,92,115,97,3,27,99,54,58,72,103,123,78,1,61,68,53,60,81,113,120,49,1,92,61,51,58,89,119,112,31,1,119,58,54,64,94,119,102,17,16,112,54,58,68,103,119,100,10,32,96,46,48,65,101,118,97,10,32,94,50,55,65,106,122,97,8,35,99,51,55,68,105,126,100,13,28,108,55,51,70,101,122,102,25,14,128,55,55,65,98,119,112,41,1,104,60,54,63,91,119,120,62,1,75,64,51,63,85,109,126,85,1,38,94,57,58,71,108,122,103,31,11,116,57,51,67,94,118,120,69,1,64,74,53,58,82,109,126,102,27,10,126,57,57,67,95,118,124,73,1,59,77,54,60,78,106,125,106,42,1,103,61,54,63,88,116,126,90,14,30,112,58,50,67,96,120,120,76,1,54,79,54,55,71,102,122,114,61,1,75,68,53,60,79,108,125,112,58,1,85,67,50,57,85,108,126,112,54,1,88,65,50,58,85,112,128,110,59,3,83,67,50,57,82,105,123,117,66,3,71,72,50,58,79,108,126,119,79,7,49,92,58,60,72,99,119,123,95,27,20,126,58,51,67,94,113,126,109,58,4,82,67,50,61,84,105,128,120,92,13,37,103,58,53,67,96,116,126,110,58,7,86,68,50,61,79,111,126,123,93,25,27,125,58,50,64,95,112,127,116,79,8,54,92,58,54,72,99,118,124,109,66,7,69,75,53,57,81,106,118,123,112,56,1,80,67,54,60,81,109,123,119,113,59,4,83,71,53,60,81,106,118,119,113,66,6,69,77,54,63,77,102,119,123,112,79,16,54,99,54,54,74,98,118,124,119,92,32,24,124,60,48,63,94,115,126,116,104,61,7,78,72,55,55,78,109,119,121,112,88,31,28,127,63,50,63,91,112,127,117,112,68,17,56,92,60,57,71,101,119,123,113,107,59,7,76,72,53,57,70,101,113,127,120,112,59,18,89,68,50,55,77,102,118,123,116,106,59,16,86,70,57,60,81,102,116,124,114,113,66,16,69,87,53,57,72,99,118,124,113,113,83,27,44,120,60,50,68,91,115,126,120,116,100,58,17,88,72,55,58,79,106,120,123,117,113,88,32,38,124,60,48,67,91,112,125,123,113,110,80,24,52,108,55,51,71,94,113,126,117,112,112,75,24,61,103,57,53,71,95,112,127,116,116,113,82,30,52,115,57,51,71,94,112,125,121,113,113,92,47,32,110,64,51,60,79,108,123,123,116,116,106,72,27,69,89,54,54,72,96,116,127,117,119,114,96,59,27,100,68,51,55,78,106,118,126,120,116,110,95,52,35,107,64,51,63,79,105,120,127,116,114,117,96,54,35,100,64,53,60,75,102,120,126,116,112,112,102,68,32,78,89,55,54,70,95,116,125,119,113,114,114,92,52,40,112,63,51,63,84,102,118,126,120,116,113,109,85,42,58,122,60,48,65,88,112,118,124,117,117,117,113,88,47,54,128,60,50,65,87,105,120,124,117,117,113,113,96,58,44,104,70,54,60,79,101,118,126,119,119,119,114,110,82,48,62,116,57,51,71,89,111,123,128,119,116,113,109,110,79,45,72,109,57,51,70,92,111,123,120,119,119,113,113,109,85,54,58,128,61,50,63,85,108,120,124,117,116,113,113,116,104,72,48,93,89,54,54,74,96,112,128,124,116,117,113,114,116,99,72,51,97,84,58,53,72,98,116,127,117,113,114,110,116,119,109,80,55,76,111,57,51,70,92,111,125,124,116,114,112,114,116,117,102,73,51,99,84,54,51,70,92,106,125,123,120,114,116,119,120,121,112,76,56,93,98,55,50,75,89,112,125,123,117,116,113,116,117,119,121,99,68,61,112,75,55,55,81,99,115,124,119,113,114,114,117,116,120,120,103,72,59,103,84,57,55,77,98,115,128,119,114,116,112,117,120,119,117,114,95,71,71,117,74,54,64,79,102,116,127,117,117,116,112,117,116,120,121,120,106,80,64,95,96,58,53,77,96,115,123,124,114,117,117,114,114,121,119,121,126,106,79,68,96,101,58,54,72,91,111,122,121,119,113,114,114,117,120,119,121,126,123,103,80,71,107,87,61,55,77,94,112,127,121,117,117,114,116,117,120,119,121,124,128,119,95,78,73,124,75,53,60,81,101,118,126,120,116,117,113,116,121,120,119,126,127,124,128,116,89,75,89,115,70,54,67,85,108,119,120,120,114,114,117,114,116,124,121,124,126,126,126,128,109,88,73,100,106,68,57,65,92,106,123,124,120,114,116,116,119,117,123,127,123,126,125,126,126,126,110,89,80,96,113,71,55,65,87,105,119,123,117,116,116,119,116,117,126,123,126,127,124,124,128,126,126,117,102,89,82,114,95,67,57,72,95,111,126,124,116,114,116,116,117,120,119,126,121,124,128,128,128,126,126,126,124,106,93,83,95,118,79,60,67,84,102,120,127,121,116,116,114,114,116,124,121,126,126,123,127,128,126,126,126,126,125,126,119,100,93,86,110,102,74,58,72,88,109,122,126,117,116,116,117,119,120,119,126,121,124,128,127,128,124,128,126,128,125,126,126,128,121,106,97,93,93,125,91,65,63,75,95,115,123,124,116,114,113,116,117,126,124,127,128,128,123,127,127,125,123,126,126,126,125,127,125,125,125,126,121,113,102,97,99,121,102,78,61,71,89,106,120,127,119,117,113,114,114,117,117,120,124,128,123,128,128,124,128,126,124,126,126,126,128,126,126,126,128,128,128,125,127,126,117,104,104,100,106,126,99,82,65,70,89,106,120,123,117,116,113,116,117,119,117,124,120,123,127,128,123,127,128,124,128,126,125,126,128,124,128,126,126,126,126,126,125,125,125,126,128,128,128,128,128,127,114,112,106,109,112,123,108,91,79,70,77,96,106,123,123,117,112,116,116,117,119,117,124,103,80,119,102,113,113,116,126,90,122,99,126,113,124,90,118,103,126,111,120,90,115,105,127,111,124,96,120,102,128,115,126,96,120,101,127,109,126,93,119,105,128,109,126,92,116,101,127,111,126,92,116,108,127,111,128,97,119,112,127,111,125,99,120,116,128,106,126,106,126,123,120,111,120,117,110,126,113,116,119,123,103,126,106,120,113,124,96,122,102,128,109,126,93,115,111,127,109,126,102,125,119,123,111,120,117,110,126,109,120,116,123,92,118,102,128,109,126,93,119,108,127,111,125,107,126,123,118,115,122,124,97,128,108,125,111,124,92,118,109,127,111,125,106,124,128,119,112,119,124,97,123,106,128,111,128,97,120,118,125,112,122,117,106,126,111,125,115,127,92,116,112,128,111,125,112,114,128,113,118,116,126,92,120,106,126,115,126,110,117,123,113,122,116,126,90,118,106,127,112,125,112,113,127,116,119,118,126,96,116,116,125,116,126,123,102,128,109,126,116,128,103,126,120,120,118,120,124,90,122,109,126,112,120,120,117,125,109,115,118,123,102,122,116,120,112,122,127,93,119,108,123,113,125,120,104,126,112,122,118,122,106,124,125,119,116,116,126,99,119,118,123,118,122,124,97,120,109,125,115,125,119,100,123,111,123,118,126,117,114,128,116,119,118,128,109,124,122,115,118,123,128,104,128,120,125,116,116,124,103,120,120,123,118,122,128,99,122,119,125,119,123,127,97,116,116,126,119,123,127,97,116,116,126,119,120,124,97,116,118,125,119,120,124,102,118,118,123,122,123,127,103,120,120,123,118,122,128,104,120,125,125,116,123,126,112,126,120,120,113,122,126,112,119,122,118,118,123,120,121,109,125,119,119,122,120,124,102,122,115,123,118,119,124,102,119,113,123,115,126,124,110,122,125,122,115,122,125,119,113,126,119,119,125,120,124,102,122,115,126,123,122,127,103,122,119,125,119,123,126,117,114,123,119,119,125,118,124,102,118,118,125,116,126,126,116,124,125,123,116,123,120,124,102,122,113,122,118,122,128,110,126,123,122,115,126,120,124,103,116,116,123,118,122,128,114,127,123,125,116,123,120,124,103,116,116,128,116,126,126,117,119,122,120,119,122,120,124,107,120,125,125,116,127,122,127,103,122,119,125,119,128,123,120,112,128,120,118,123,123,127,114,126,122,125,119,127,118,124,107,119,123,125,119,127,122,127,103,120,120,125,119,127,128,127,106,122,122,125,120,127,125,124,117,122,120,119,125,125,127,116,119,128,120,120,126,126,126,119,119,123,122,125,125,126,127,121,119,128,120,120,123,128,128,120,119,126,120,125,125,125,125,120,116,128,120,125,125,125,125,124,112,128,115,119,116,122,123,127,112,118,115,125,118,126,120,126,112,118,122,128,116,128,122,127,116,120,125,125,119,128,123,127,120,124,125,125,122,123,128,128,127,113,123,122,125,123,128,125,125,114,120,125,125,123,128,128,128,124,120,126,122,125,123,128,125,127,113,118,125,125,123,128,128,128,124,120,126,122,125,123,128,128,127,114,119,125,125,123,128,128,128,127,119,126,122,125,125,125,126,127,114,122,126,125,123,128,125,128,127,114,119,123,125,123,123,128,128,127,119,125,125,125,123,128,128,128,124,126,123,125,125,125,126,126,126,120,126,125,125,123,123,128,128,128,119,120,123,123,123,125,127,128,128,119,120,125,125,125,123,128,128,128,120,123,123,128,119,126,128,128,128,120,123,123,128,123,123,123,123,127,120,123,125,125,119,128,128,123,126,121,127,126,120,125,125,125,125,125,127,121,125,125,125,125,123,128,128,128,119,120,123,128,125,128,128,125,125,124,125,125,125,125,126,126,126,126,126,120,126,120,126,125,123,128,128,128,120,123,125,125,123,128,123,128,128,128,123,126,125,125,125,123,128,123,128,123,123,125,125,123,128,128,128,128,128,121,123,125,125,125,125,126,126,126,126,121,125,125,125,125,125,126,126,126,126,126,125,125,125,125,126,126,126,126,126,127,125,125,125,125,126,126,126,126,124,125,125,125,125,126,126,126,126,126,126,123,127,125,125,127,125,125,125,125,127,127,125,125,125,125,126,126,126,126,127,126,126,125,125,125,125,126,127,125,127,121,125,125,127,125,125,125,127,125,127,126,123,125,127,125,127,125,125,125,127,127,126,123,125,125,125,126,126,126,122,127,128,123,123,123,122,126,122,126,128,123,128,128,128,123,128,123,128,128,128,128,128,127,127,125,127,125,125,125,125,126,126,126,126,125,125,125,126,126,126,126,128,128,128,127,125,125,125,125,126,126,126,126,126,126,127,125,125,125,125,126,125,125,127,125,127,127,125,125,125,125,126,126,126,126,125,125,127,125,125,125,125,126,125,125,125,125,126,125,127,125,127,127,125,125,127,125,127,125,127,127,125,125,125,125,127,125,125,125,126,128,128,127,125,127,125,125,0};
  2. int shoot_numberOfSamples = 4080; //removed all negatives from []
  3. int shoot_sampleRate = 8;