AddDevices.bat 1.1 KB

12345678910111213141516171819202122
  1. @echo off
  2. REM Register hardware devices in the spectrometer database (run once after first start)
  3. curl -s -X POST -H "Content-Type: application/json" ^
  4. -d "{\"device_type\": \"ADC\", \"brend\": \"Picoscope\", \"serial_model\": \"PS4000A\", \"proto\": \"adc_default\", \"proto_interface\": \"TCP\"}" ^
  5. http://localhost:8000/api/devices/
  6. curl -s -X POST -H "Content-Type: application/json" ^
  7. -d "{\"device_type\": \"SDR\", \"brend\": \"HackRF\", \"serial_model\": \"HackRF\", \"proto\": \"sdr_default\", \"proto_interface\": \"USB\"}" ^
  8. http://localhost:8000/api/devices/
  9. curl -s -X POST -H "Content-Type: application/json" ^
  10. -d "{\"device_type\": \"SYNC\", \"brend\": \"Arduino\", \"serial_model\": \"DuePP\", \"proto\": \"sync_default\", \"proto_interface\": \"USB\"}" ^
  11. http://localhost:8000/api/devices/
  12. curl -s -X POST -H "Content-Type: application/json" ^
  13. -d "{\"device_type\": \"GRA\", \"brend\": \"ITMO\", \"serial_model\": \"GRU\", \"proto\": \"gra_default\", \"proto_interface\": \"UDP\"}" ^
  14. http://localhost:8000/api/devices/
  15. echo.
  16. echo Devices registered.
  17. pause