mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-02-22 12:23:57 +08:00
* lgtm in readme, and mac nui fixes
* call super inits in radars
* unused imports, dup lines
* more radars, more unused imports
* pass CP into RadarInterfaceBase
* more fixups
* unused imports
* delete unused lines
* ugh, new unused import
Co-authored-by: George Hotz <geohot@gmail.com>
old-commit-hash: 1295cfe06c
17 lines
372 B
Python
Executable File
17 lines
372 B
Python
Executable File
#!/usr/bin/env python3
|
|
import cereal.messaging as messaging
|
|
import pcap
|
|
|
|
def main():
|
|
ethernetData = messaging.pub_sock('ethernetData')
|
|
|
|
for ts, pkt in pcap.pcap('eth0'):
|
|
dat = messaging.new_message('ethernetData', 1)
|
|
dat.ethernetData[0].ts = ts
|
|
dat.ethernetData[0].pkt = str(pkt)
|
|
ethernetData.send(dat.to_bytes())
|
|
|
|
if __name__ == "__main__":
|
|
main()
|
|
|