New to CAN

This forum covers issues concerning multiple hardware products.
Post Reply
WorkInProgress
Posts: 2
Joined: Thu 25. Jul 2024, 04:49

New to CAN

Post by WorkInProgress » Thu 25. Jul 2024, 04:57

Hello, I am working on a CY8KIT-059 CAN Protocol. I have bought a PCAN-USB.

I have the Rx and Tx pins from the board being attached to the CAN Low, and CAN High pins using jumper cables. Proper termination with 120ohm resistor is being used via a connection through a breadboard (I understand this rig is a bit wacky).

My code is set up to transmit incrementing values, however, when I go on PCAN-View Trace option, only one thing is being displayed Rx, Type: Status, Length:4, Data: BUSHEAVY, I have attached a picture. Any ideas on what could be wrong?

Feel free to ask more questions/request pictures, as I would really like this to work.

Forgive me for being new to this all, as I am sure there are better questions being asked.
Attachments
help.PNG
help.PNG (4.92 KiB) Viewed 6288 times

User avatar
PEAK-Supporter
Sales & Support
Sales & Support
Posts: 1647
Joined: Fri 10. Sep 2010, 19:34

Re: New to CAN

Post by PEAK-Supporter » Thu 25. Jul 2024, 08:21

As no one knows what exact you do, it is hard to answer .....

As you get a physical Error (BUSHEAVY - to many erro frames - counter reach the Top Level) check the CAN Basic
  • exact timing
  • good cables
  • correct termination (2 x 120 Ohm resistors on each end of the CAN-H / CAN-L lines )
In PCAN-View you also have a online help that explain s the errors - press F1.
Also spend some tie in reading the CAN Layer 2 specification.
--------------------------------
PEAK-System Technik
Technical Support Team
support[at]peak-system.com
-------------------------------

WorkInProgress
Posts: 2
Joined: Thu 25. Jul 2024, 04:49

Re: New to CAN

Post by WorkInProgress » Thu 25. Jul 2024, 18:50

Thank you for your reply! I think something I first want to check is the timing. My board runs at 24MHz, while the PCAN-View (CANSJA1000) works at 8MHz. Below is the timing I have picked for both, and I am wondering if they are valid configurations. I have used the Peak Bit Rate calculator tool to do this-- however, I am no professional and would like a second pair of eyes.
Attachments
Board Timing Configuration
Board Timing Configuration
board timing.PNG (318.38 KiB) Viewed 6259 times
PCAN-View Timing Configuration
PCAN-View Timing Configuration
PCAN View.PNG (4.76 KiB) Viewed 6259 times

User avatar
PEAK-Supporter
Sales & Support
Sales & Support
Posts: 1647
Joined: Fri 10. Sep 2010, 19:34

Re: New to CAN

Post by PEAK-Supporter » Thu 25. Jul 2024, 19:53

The frequency is not the problem. You could use a pre-scaler. But search for a pair of timing parameter that fit. The most important value is the Sample point (try values between 75-85%)
--------------------------------
PEAK-System Technik
Technical Support Team
support[at]peak-system.com
-------------------------------

Post Reply