Hi please excuse me if this is a dumb question.

I'm making a small machine, driving 3 steppers, and the connection between the computer (linux OS) and the controller (Raspberry pi Compute Module) is meant to be serial. However I am very Used to SSH comunications, so is ssh as reliable as serial cable, excluding possible network problems? What would be the best solution to this problem.

Maybe getting the computemodule to act as a DHCP server?

The stepper drive receives a pulse train from the controller, so maybe just a cable from the raspberry pi to the signal input would be enough.

I'm using python, and my plan is to use paramiko in order to run the scripts that move the stepper drives.

  • 1
    A serial cable is a hardware transport mechanism made up of signal wires. SSH is a software secure protocol used to login to computers. They are not comparable. I'm not sure where DHCP or steppers or paramiko come into this. Perhaps you would be better off concentrating on one question at a time.
    – joan
    Feb 4, 2016 at 23:33
  • well I could have my python scripts on the compute module , and execute them via ssh with paramiko , instead of expecting a serial input , but I need a way to make this work without being dependent on the network of the industry Feb 4, 2016 at 23:39
  • 1
    setting up a network just to run ssh is a huge hassle, when a serial connection is literally just plug and go on most OSs. Feb 4, 2016 at 23:40
  • 1
    Also, ssh and the serial console are almost identical. Feb 5, 2016 at 4:16

2 Answers 2


SSH has been designed for Shells , for arbitary serial data use Ser2Net instead !

Here is a tutorial on how to use Ser2net to replace serial cables with an IP network :


Note: The Python program controlling the serial port has to run on your Linux desktop now !

  • thanks for the answer , this kind of solution was what I was looking for Feb 5, 2016 at 19:33

SSH and serial are just different methods of getting your hands on a command line. Basically, SSH isn't a substitute in the first place. It's a different method of accessing the same thing.

If your project won't kill anyone when you disconnect from the command line, SSH is, in my opinion, a more convenient way to access the command line. Just think about all the wires (3) you have to take care of when using the serial port.

Take note that any foreground script or program you launched in that SSH session will die if you disconnect. If you don't want that to happen, use the screen command before you do anything.

And no, you don't need to mess with any complicated networking stuff. Just connect the pi to your network and access it using its IP address. Oh, you don't know the Pi's IP address? Use SoftPerfect network scanner. (personal choice, not sponsored). Your Pi's MAC address will start with B8-27-EB.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.