diff --git a/README.md b/README.md index fdf9fd5..df3f2fd 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ -Welcome to panda -====== +# Welcome to panda [panda](http://github.com/commaai/panda) is the nicest universal car interface ever. @@ -15,30 +14,29 @@ It is 2nd gen hardware, reusing code and parts from the [NEO](https://github.com ![panda tests](https://github.com/commaai/panda/workflows/panda%20tests/badge.svg) -Usage (Python) ------- +## Usage + +### Python To install the library: -``` -# pip install pandacan +``` bash +pip install pandacan ``` See [this class](https://github.com/commaai/panda/blob/master/python/__init__.py#L80) for how to interact with the panda. For example, to receive CAN messages: -``` +``` python >>> from panda import Panda >>> panda = Panda() >>> panda.can_recv() ``` And to send one on bus 0: -``` +``` python >>> panda.can_send(0x1aa, "message", 0) ``` -Find user made scripts on the [wiki](https://community.comma.ai/wiki/index.php/Panda_scripts) - Note that you may have to setup [udev rules](https://community.comma.ai/wiki/index.php/Panda#Linux_udev_rules) for Linux, such as -``` +``` bash sudo tee /etc/udev/rules.d/11-panda.rules <