CANDUMP(1)

πŸ“¦
version 2023.03 Β· 3 versions
, in ubuntu resolute, ubuntu stonking

✨ CANDUMP(1) ✨

okay bestie, it's a User Commands page, and it's literally called candump. Pull up a chair πŸ’–


🌸 NAME 🌸

candump β€” the manual page for candump 2023.03-1build1


πŸŽ€ SYNOPSIS πŸŽ€

candump [options] <CAN interface>+

πŸ¦‹ DESCRIPTION πŸ¦‹

candump β€” dump CAN bus traffic. that's it, that's the whole job πŸ’…

(use CTRL+C to terminate candump)

like, actually use it. it will just keep going otherwise. no cap.


πŸ‘‘ OPTIONS πŸ‘‘

  • -t <type> β€” sets the timestamp style: (a)bsolute / (d)elta / (z)ero / (A)bsolute w date
  • -H β€” read hardware timestamps instead of system timestamps
  • -c β€” increments the color mode level 🌈 (yes you can stack it, it's giving gradient)
  • -i β€” binary output β€” heads up, this may exceed 80 chars/line
  • -a β€” enable additional ASCII output
  • -S β€” swaps the byte order in the printed CAN data[] β€” those swapped ones get marked with a `
  • -s <level> β€” silent mode: 0: off (that's the default), 1: animation, 2: silent
  • -l β€” logs CAN-frames into a file. this sets -s 2 by default
  • -f <fname> β€” logs CAN-frames into the file <fname>. also sets -s 2 by default
  • -L β€” use log file format on stdout
  • -n <count> β€” terminate after receiving <count> CAN frames
  • -r <size> β€” set the socket receive buffer to <size>
  • -D β€” Don't exit if a "detected" can device goes down (capital D for Don't, iconic)
  • -d β€” monitor dropped CAN frames
  • -e β€” dump CAN error frames in human-readable format
  • -8 β€” display raw DLC values in {} for Classical CAN
  • -x β€” print extra message infos: rx/tx brs esi
  • -T <msecs> β€” terminate after <msecs> if no frames were received

up to 16 CAN interfaces with optional filter sets can be specified on the commandline, in this form:

<ifname>[,filter]*

πŸ” Filters πŸ”

comma separated filters can be specified for each given CAN interface, and here's the whole menu:

  • <can_id>:<can_mask> β€” matches when <received_can_id> & mask == can_id & mask
  • <can_id>~<can_mask> β€” matches when <received_can_id> & mask != can_id & mask
  • #<error_mask> β€” sets the error frame filter, see include/linux/can/error.h
  • [j|J] β€” joins the given CAN filters β€” logical AND semantic

CAN IDs, masks and data content are given and expected in hexadecimal values. when the can_id is 8 digits long, the CAN_EFF_FLAG is set for 29 bit EFF format. without any given filter, all data frames are received (the '0:0' default filter). 🫢

use interface name 'any' to receive from all CAN interfaces. she's flexible like that.


⭐ EXAMPLES ⭐

candump -c -c -ta can0,123:7FF,400:700,#000000FF can2,400~7F0 can3 can8
candump -l any,0~0,#FFFFFFFF
(log only error frames but no(!) data frames)
candump -l any,0:0,#FFFFFFFF
(log error frames and also all data frames)
candump vcan2,12345678:DFFFFFFF
(match only for extended CAN ID 12345678)
candump vcan2,123:7FF
(matches CAN ID 123 β€” including EFF and RTR frames)
candump vcan2,123:C00007FF
(matches CAN ID 123 β€” only SFF and non-RTR frames)

πŸ’œ SEE ALSO πŸ’œ

nothing here bestie, this page didn't list any SEE ALSO refs β€” go forth and dump πŸ¦‹

that's the whole vibe check, you're officially a candump girlie now πŸ‘‘

candump 2023.03-1build1 β€” December 2025 β€” mwah, drink water, and remember: Ctrl+C is your bestie πŸ’–βœ¨

πŸ“¦ where this page comes from