Arduino Ground Station Commands

I'm working on a bench top technology demonstration project for controlling a pointing mechanism aboard a spacecraft or high altitude balloon. On board the system is an Arduino Uno attached to a pair of stepper motors which control the pointing mechanism. The Arduino sketch I created essentially converts my desired pointing direction into the required number of steps. This portion works fine when I have my Arduino plugged into my PC and I upload a new sketch every time I update my desired pointing direction.

For flight, I need to send an RF signal/file to the flight computer aboard the actual Bus, and then have the flight computer upload that into the arduino via USB.

  1. I plan to use a Raspberry Pi to simulate my flight computer in my bench setup. Does anyone know how I would go about sending my .ino to the pi, and then have the pi automatically upload the sketch into the arduino?
  2. Is there a way to a less data intensive way to send a command other than uploading the whole sketch? Currently only a single variable ("degreesDesired") is changed when I need to adjust my pointing direction.

Thanks for any help!

I'm not a Raspberry Pi expert but if the Raspberry Pi USB can emulate a serial port can't you just pass the value for degreesDesired over that? You can test it with the PC since it also does serial port emulation. You could also use direct pin to pin from RP to Arduino if you can assign Tx and Rx to pins on the RP and use Software Serial on the Arduino.

Also wondering why you can't just control the motors with the flight computer (RP). Why do you need 2 separate devices?