Newer
Older
pyenergenie / src / energenie / drv / build_rpi
  1. #! /bin/bash
  2.  
  3. # build file for Raspberry Pi use
  4.  
  5. # build gpio_test
  6. gcc gpio_test.c gpio_rpi.c delay_posix.c
  7. mv a.out gpio_test
  8. chmod u+x gpio_test
  9.  
  10.  
  11. # build spis_test (soft SPI tester)
  12. gcc spi_test.c spis.c gpio_rpi.c delay_posix.c
  13. mv a.out spis_test
  14. chmod u+x spis_test
  15.  
  16.  
  17. # build spih_test (hard SPI tester)
  18. ##gcc spi_test.c spih_rpi.c gpio_rpi.c
  19. ##mv a.out spih_test
  20. ##chmod u+x spish_test
  21.  
  22.  
  23. # build hrf69_test
  24. gcc hrfm69_test.c hrfm69.c spis.c gpio_rpi.c delay_posix.c
  25. mv a.out hrfm69_test
  26. chmod u+x hrfm69_test
  27.  
  28.  
  29. # build radio_test
  30. gcc radio_test.c radio.c hrfm69.c spis.c gpio_rpi.c delay_posix.c
  31. mv a.out radio_test
  32. chmod u+x radio_test
  33.  
  34.  
  35. # radio .so library on Raspberry Pi
  36. gcc -Wall -shared -o radio_rpi.so -fPIC radio.c hrfm69.c spis.c gpio_rpi.c delay_posix.c
  37. ##nm -D radio_rpi.so
  38.  
  39. # END