hardbyte / hardbyte/python-can

Meaning of can.BusABC.state

Aberta
#736 13 comentários 3 reações 0 responsáveis Ver no GitHub
api
Linguagem predominante
Python
Estrelas
1.6k
Forks
697
Métricas de merge de PRs
Nenhum PR com merge em 30d

Descrição

Hello,
please help me understand the meaning of `class BusState(Enum):`. I would like to show status of the interface (Kvaser Leaf and Vector VN1610 are on my desk) as specified by CAN specification (error active, error passive and bus-off state).
But the @property `def state(self):` of the classes `class KvaserBus(BusABC):` and `class VectorBus(BusABC):` are not implemented.

I would like to implement them but I am not sure what it shall returns
- state of the CAN bus as defined by standard (active, passive, error=busoff)
- state of the Python class BusABC (active, passive=silent_mode, error=some_driver)

The documentation says that it returns ["current state of the hardware"](https://python-can.readthedocs.io/en/master/bus.html#can.BusABC.state). Does it mean state of driver connection with HW interface or state of CAN bus controller (active->passive->busoff)?

Guia de contribuição

Abrir o guia de contribuição

Direção de pesquisa

Start with the BusState enum and the BusABC.state documentation, then inspect the unimplemented state properties in KvaserBus and VectorBus. Resolve whether the property represents CAN controller state or the Python driver's hardware connection state; done means the intended contract is decided and consistently documented or implemented for both classes.

Escrita pelo modelo de indexação a partir do texto da issue.

Avaliação

Stack de tecnologia
python
Domínio
embedded-iot, networking
Tipo de issue
Funcionalidade
Dificuldade
4/5
Tempo estimado
3-5 dias
Status de atividade
Estagnada
Clareza
Precisa de esclarecimento
Facilidade para iniciantes
25/100

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.