The system install should have put a udev rule in place. This causes the
kernel to create an alias to the device whenever it detects it plugging in
(or at boot). Because if you have more than one serial device the envoy
could get a different device name (ttyUSB1, ttyUSB3, etc.) every time it
plugs in (like after a power bounce).
You can read the rules at /usr/lib/udev/rules.d/60-weewx.rules. The
idVendor and idProduct values match what you saw in the lsdev command.

## udev rule
SUBSYSTEM=="tty",ATTRS{idVendor}=="10c4",ATTRS{idProduct}=="ea61",MODE="0664",GROUP="weewx",SYMLINK+="vantage"

## lsusb
Bus 001 Device 002: ID 10c4:ea61 Silicon Labs CP210x UART Bridge

If that worked you should see  /dev/ttyUSB0 with group weewx and
/dev/vantage as a symlink to ttyUSB0.

#> ls -l /dev |grep USB
crw-rw-r-- 1 root weewx   188,   0 Feb  3 14:10 ttyUSB0
lrwxrwxrwx 1 root root           7 Jan 31 09:59 vantage -> ttyUSB0

So... your weewx.conf file should point to /dev/vantage

    # If the connection type is serial, a port must be specif
    #   Debian, Ubuntu, Redhat, Fedora, and SuSE:
    #     /dev/ttyUSB0 is a common USB port name
    #     /dev/ttyS0   is a common serial port name
    #   BSD:
    #     /dev/cuaU0   is a common serial port name
    port = /dev/vantage



On Mon, Feb 3, 2025 at 1:39 PM scott pierce <johnscottpie...@gmail.com>
wrote:

> This is getting a tad frustrating!
>
> On Monday, February 3, 2025 at 12:37:32 PM UTC-5 Tom Keffer wrote:
>
>> Now you're back to a permissions error.
>>
>> On Mon, Feb 3, 2025 at 9:26 AM scott pierce <johnsco...@gmail.com> wrote:
>>
>>> *Doesn't look like it worked.*
>>>
>>> × weewx.service - WeeWX
>>>      Loaded: loaded (/lib/systemd/system/weewx.service; enabled; preset:
>>> enabled)
>>>      Active: failed (Result: exit-code) since Mon 2025-02-03 12:18:41
>>> EST; 5min ago
>>>    Duration: 5min 21.472s
>>>        Docs: https://weewx.com/docs
>>>     Process: 1103 ExecStart=weewxd /etc/weewx/weewx.conf (code=exited,
>>> status=4)
>>>    Main PID: 1103 (code=exited, status=4)
>>>         CPU: 411ms
>>>
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL weewx.engine:     ****
>>>  File "/usr/share/weewx/weewx/drivers/vantage.py", line 1444, in _setup
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL weewx.engine:     ****
>>>  self.hardware_type = self._determine_hardware()
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL weewx.engine:     ****
>>>                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL weewx.engine:     ****
>>>  File "/usr/share/weewx/weewx/drivers/vantage.py", line 1435, in
>>> _determine_hardware
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL weewx.engine:     ****
>>>  raise weewx.WeeWxIOError("Unable to read hardware type")
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL weewx.engine:     ****
>>>  weewx.WeeWxIOError: Unable to read hardware type
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL __main__: Unable to load
>>> driver: Unable to read hardware type
>>> Feb 03 12:18:41 spi-1 weewxd[1103]: CRITICAL __main__:     ****
>>>  Exiting...
>>> Feb 03 12:18:41 spi-1 systemd[1]: weewx.service: Main process exited,
>>> code=exited, status=4/NOPERMISSION
>>> Feb 03 12:18:41 spi-1 systemd[1]: weewx.service: Failed with result
>>> 'exit-code'.
>>> ~
>>>
>>>
>>> On Monday, February 3, 2025 at 12:06:53 PM UTC-5 Tom Keffer wrote:
>>>
>>>> There have been a few other incidents of "Unknown hardware type 10".
>>>> The solution seems to be to clear the logger. Try this procedure:
>>>>
>>>>  weectl device --dump
>>>>  weectl device --clear-memory
>>>>
>>>> The "--dump" command will attempt to salvage any data on the logger. It
>>>> will probably fail because of the "unknown hardware type" error, but it's
>>>> worth a try.
>>>>
>>>> -tk
>>>>
>>>> On Mon, Feb 3, 2025 at 8:34 AM scott pierce <johnsco...@gmail.com>
>>>> wrote:
>>>>
>>>>> *Yep, WeeWx is already a member of that group. Here is the latest
>>>>> systems status I just ran.  Seems the unknown hardware issue is still
>>>>> there.  *
>>>>> *Is there another log or status that I can run that will provide
>>>>> more/complete information?*
>>>>> *Thanks*
>>>>> *Scott*
>>>>>
>>>>>      Loaded: loaded (/lib/systemd/system/weewx.service; enabled;
>>>>> preset: enabled)
>>>>>      Active: failed (Result: exit-code) since Mon 2025-02-03 11:17:57
>>>>> EST; 11min ago
>>>>>    Duration: 9min 1.723s
>>>>>        Docs: https://weewx.com/docs
>>>>>     Process: 1091 ExecStart=weewxd /etc/weewx/weewx.conf (code=exited,
>>>>> status=4)
>>>>>    Main PID: 1091 (code=exited, status=4)
>>>>>         CPU: 474ms
>>>>>
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL weewx.engine:     ****
>>>>>  File "/usr/share/weewx/weewx/drivers/vantage.py", line 540, in __init__
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL weewx.engine:     ****
>>>>>    log.debug("Hardware name: %s", self.hardware_name)
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL weewx.engine:     ****
>>>>>                                   ^^^^^^^^^^^^^^^^^^
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL weewx.engine:     ****
>>>>>  File "/usr/share/weewx/weewx/drivers/vantage.py", line 1416, in
>>>>> hardware_name
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL weewx.engine:     ****
>>>>>    raise weewx.UnsupportedFeature("Unknown hardware type %d" %
>>>>> self.hardware_type)
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL weewx.engine:     ****
>>>>>  weewx.UnsupportedFeature: Unknown hardware type 10
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL __main__: Unable to load
>>>>> driver: Unknown hardware type 10
>>>>> Feb 03 11:17:57 spi-1 weewxd[1091]: CRITICAL __main__:     ****
>>>>>  Exiting...
>>>>> Feb 03 11:17:57 spi-1 systemd[1]: weewx.service: Main process exited,
>>>>> code=exited, status=4/NOPERMISSION
>>>>> Feb 03 11:17:57 spi-1 systemd[1]: weewx.service: Failed with result
>>>>> 'exit-code'.
>>>>>
>>>>>
>>>>>
>>>>> On Sunday, February 2, 2025 at 11:46:26 PM UTC-5 Graham Eddy wrote:
>>>>>
>>>>>> weewx is reporting permission error. it seems to be using
>>>>>> /dev/ttyUSB0 ➔ check perms on that file:
>>>>>>   $ ls -l /dev/ttyUSB0
>>>>>> it will probably show group ‘dialout’ has read/write on it, so make
>>>>>> sure user ‘weewx’ is in that group
>>>>>>   e.g. $ sudo adduser weewx dialout
>>>>>> *⊣GE⊢*
>>>>>>
>>>>>> On 3 Feb 2025, at 1:36 pm, vince <vince...@gmail.com> wrote:
>>>>>>
>>>>>> All I can suggest is (a) verify which groups 'weewx' is in and (b)
>>>>>> perhaps try to run weewx interactively - just run "weewxd" and it should 
>>>>>> do
>>>>>> the right thing thing
>>>>>>
>>>>>>
>>>>>> --
>>>>> 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 weewx-user+...@googlegroups.com.
>>>>>
>>>> To view this discussion visit
>>>>> https://groups.google.com/d/msgid/weewx-user/7130ad30-8260-446c-b676-92c76e65f813n%40googlegroups.com
>>>>> <https://groups.google.com/d/msgid/weewx-user/7130ad30-8260-446c-b676-92c76e65f813n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>> .
>>>>>
>>>> --
>>> 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 weewx-user+...@googlegroups.com.
>>>
>> To view this discussion visit
>>> https://groups.google.com/d/msgid/weewx-user/7cc63d2d-ee8e-40c2-9b9b-43a5f341064en%40googlegroups.com
>>> <https://groups.google.com/d/msgid/weewx-user/7cc63d2d-ee8e-40c2-9b9b-43a5f341064en%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>> --
> 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 weewx-user+unsubscr...@googlegroups.com.
> To view this discussion visit
> https://groups.google.com/d/msgid/weewx-user/ce23e1ce-4fe9-407d-9050-79a1830aa00fn%40googlegroups.com
> <https://groups.google.com/d/msgid/weewx-user/ce23e1ce-4fe9-407d-9050-79a1830aa00fn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
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 weewx-user+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/weewx-user/CA%2Bz%2BvD4wfCGKTZ%2BLmo0WyMDML3Giqu%2BCJ%2B4W9Z0cBJPAJGf3bQ%40mail.gmail.com.

Reply via email to