(Dec-15-2021, 03:37 PM)the_dude Wrote: This is what my list looks like if I were to just print it without trying to convert it to a float ['0.38', '0.42', '0.52', ", ", '', '', '', '', '']
Python's
float
function doesn't accept the empty string for conversion, and that's what you have for the later values in your list.You should detect if you don't get any value from your serial and continue the loop or return a 0 since it won't affect your sum.