I am working on a project where the speed of the ball is controlled by a potentiometer via arduino but the directions are controlled by the keyboard keys. My code is not working, the ball does'nt move.

using UnityEngine;
using System.Collections;
using System.IO.Ports;

public class Playercontroller : MonoBehaviour {

private bool arduinoOn = true;
SerialPort sp = new SerialPort("COM17", 9600);
//public float speed;
void Start () 
		sp.Open ();
		sp.ReadTimeout = 1;

void FixedUpdate () 

	float movehor = Input.GetAxis ("Horizontal");
	float movever = Input.GetAxis ("Vertical");
	float speed = sp.ReadByte ();
	Vector3 movement = new Vector3 (movehor, 0.0f, movever);

	rigidbody.AddForce(movement* speed* Time.deltaTime);


Can someone explain where the code is wrong. Thanks

Thanks guys. I have solved the problem. The arduino code needed to be changed from print to serial.write. Plus the entire unity code needed to be shifted to update()