Not much a pyserial whip but since your original working code read up to 10 
characters maybe try something like 

            x = self.serial_port.read(10)
            v = float(x[2:8])

Probably should wrap a try..except around the float in case you read 
garbage from the serial port:

            x = self.serial_port.read(10)
            try:
                v = float(x[2:8])
            except ValueError:
                v = None

Careful with the try..except though, you can all to easily swallow up 
errors and spend a lot of time looking in the wrong place if things don't 
work as planned.

Gary

On Sunday, 25 November 2018 12:09:32 UTC+10, KattanaD wrote:
>
> Ok fixed my last error with my weewx.conf having some garbage at the 
> beginning
>  and did some driver configuring trying the variables could not convert 
> string to float 
>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to