Can't store the values I get from my temperature in the database.

sp1 = new SerialPort("COM4", 9600);
sp1.Open();

sp1.open() should be in a try catch construct as it can throw exceptions. ignoring them makes code less robust.


update: oops I cross-answered ...