mirror of
https://github.com/infiniteCable2/panda.git
synced 2026-02-19 17:53:53 +08:00
* fix W391 * E262 * E703 * W293 * some E * E231 * some more E * E225 * more E * E252 * no tabs * more tabs * E701 * uds.py * almost all of them * only e265 left * not sure why this is triggering on commented out code * ignore esptool
23 lines
405 B
Python
Executable File
23 lines
405 B
Python
Executable File
#!/usr/bin/env python3
|
|
import time
|
|
from panda import Panda
|
|
|
|
p = Panda()
|
|
p.set_safety_mode(Panda.SAFETY_ALLOUTPUT)
|
|
|
|
# hack anything on bus
|
|
p.set_gmlan(bus=2)
|
|
time.sleep(0.1)
|
|
while len(p.can_recv()) > 0:
|
|
print("clearing")
|
|
time.sleep(0.1)
|
|
print("cleared")
|
|
p.set_gmlan(bus=None)
|
|
|
|
iden = 18000
|
|
dat = "\x01\x02\x03\x04\x05\x06\x07\x08"
|
|
while 1:
|
|
iden += 1
|
|
p.can_send(iden, dat, bus=3)
|
|
time.sleep(0.01)
|