mirror of
https://github.com/DreamSourceLab/DSView.git
synced 2025-02-02 13:52:55 +08:00
Fix: The CAN decoder AND CAN_FD
This commit is contained in:
parent
5d36d0654b
commit
dd95035331
@ -141,7 +141,15 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "dec_can_opt_bitrate",
|
"id": "dec_can_opt_bitrate",
|
||||||
"text": "比特率"
|
"text": "波特率"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "dec_can_opt_nominal_bitrate",
|
||||||
|
"text": "低波特率"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "dec_can_opt_fast_bitrate",
|
||||||
|
"text": "高波特率"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "dec_can_opt_sample_point",
|
"id": "dec_can_opt_sample_point",
|
||||||
|
@ -39,12 +39,12 @@ class Decoder(srd.Decoder):
|
|||||||
outputs = ['can']
|
outputs = ['can']
|
||||||
tags = ['Automotive']
|
tags = ['Automotive']
|
||||||
channels = (
|
channels = (
|
||||||
{'id': 'can_rx', 'name': 'CAN FD', 'desc': 'CAN FD bus line', 'idn':'dec_can_fd_chan_can_rx'},
|
{'id': 'can_rx', 'name': 'CAN FD', 'desc': 'CAN FD bus line', 'idn':'dec_can_chan_can_rx'},
|
||||||
)
|
)
|
||||||
options = (
|
options = (
|
||||||
{'id': 'nominal_bitrate', 'desc': 'Nominal bitrate (bits/s)', 'default': 1000000, 'idn':'dec_can_fd_opt_nominal_bitrate'},
|
{'id': 'nominal_bitrate', 'desc': 'Nominal bitrate (bits/s)', 'default': 1000000, 'idn':'dec_can_opt_nominal_bitrate'},
|
||||||
{'id': 'fast_bitrate', 'desc': 'Fast bitrate (bits/s)', 'default': 2000000, 'idn':'dec_can_fd_opt_fast_bitrate'},
|
{'id': 'fast_bitrate', 'desc': 'Fast bitrate (bits/s)', 'default': 2000000, 'idn':'dec_can_opt_fast_bitrate'},
|
||||||
{'id': 'sample_point', 'desc': 'Sample point (%)', 'default': 70.0, 'idn':'dec_can_fd_opt_sample_point'},
|
{'id': 'sample_point', 'desc': 'Sample point (%)', 'default': 70.0, 'idn':'dec_can_opt_sample_point'},
|
||||||
)
|
)
|
||||||
annotations = (
|
annotations = (
|
||||||
('data', 'CAN payload data'),
|
('data', 'CAN payload data'),
|
||||||
|
@ -42,8 +42,8 @@ class Decoder(srd.Decoder):
|
|||||||
{'id': 'can_rx', 'name': 'CAN', 'desc': 'CAN bus line', 'idn':'dec_can_chan_can_rx'},
|
{'id': 'can_rx', 'name': 'CAN', 'desc': 'CAN bus line', 'idn':'dec_can_chan_can_rx'},
|
||||||
)
|
)
|
||||||
options = (
|
options = (
|
||||||
{'id': 'bitrate', 'desc': 'bitrate (bits/s)', 'default': 1000000,'idn':'dec_can_opt_bitrate'},
|
{'id': 'bitrate', 'desc': 'bitrate (bits/s)', 'default': 1000000,'idn':'dec_can_opt_bitrate'},
|
||||||
{'id': 'sample_point', 'desc': 'Sample point (%)', 'default': 70.0,'idn':'dec_can_opt_sample_point'},
|
{'id': 'sample_point', 'desc': 'Sample point (%)', 'default': 70.0,'idn':'dec_can_opt_sample_point'},
|
||||||
)
|
)
|
||||||
annotations = (
|
annotations = (
|
||||||
('data', 'CAN payload data'),
|
('data', 'CAN payload data'),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user