SN65HVD230 CAN transceiver module output signal is not differential - Page 1
Forum section: electronics / beginners

author: syntax333
author_rank: Regular Contributor
timestamp: September 30, 2022, 05:45:55 am
content: I am working on a project where I have to communicate with CAN protocol. Therefore, I bought SN65HVD230 CAN transceiver module to connect it to my STM32F429ZI Nucleo board. I am giving 3V3 from Nucleo boards 3V3 output to transceiver.The problem is, if I scope the output of CANH and CANL the signal is not differential. I switched the IC in case it got fried during my testing but it seems to behave same. Also can't receive the signal when I connect CAN transceiver module to the CAN to USB converter (probably because signal is not differential).I attached the screen of the scope. Blue and Yellow lines are CANH and CANL.Edit: I also realized that Vref pin is switching with the CANH and CANL signal but in datasheet it is stated that Vref=Vcc/2. Vcc is stable 3.3V. Why would it switch with CANH and CANL.

author: darkspr1te
author_rank: Frequent Contributor
timestamp: September 30, 2022, 06:17:32 am
content: Are you doing the measurements on the chip while it is connected to another chip? eg CAN H to CANH and CAN L to CAN L with termination ?darkspr1te

author: syntax333
author_rank: Regular Contributor
timestamp: September 30, 2022, 06:33:28 am
content: I did the measurement both when CANH and CANL is open and when CAN-to-USB is connected.The scoped image in first post is when CANH and CANL is floating.When I connect the CAN to USB converter to CANH and CANL it is the same signal in first image but with level shift.

author: jwet
author_rank: Frequent Contributor
timestamp: September 30, 2022, 06:34:00 am
content: As said above, you have to at least terminate the with usually 60 ohms for HS CAN- this is just for test- in use, you will have a 120 ohm termination on each end of a CAN bus. These TI parts were specifically designed for 3.3v single supply and are a little odd. They pass the CAN homologation tests but don't act like most old style CAN Xcvrs. The original CAN Phy's that these are based on is the NXP82C250. They appear to be working as I would expect and will likely work fine in a system.

author: syntax333
author_rank: Regular Contributor
timestamp: September 30, 2022, 06:47:18 am
content: Image is when CAN-USB converter is connected.

author: jwet
author_rank: Frequent Contributor
timestamp: September 30, 2022, 06:57:06 am
content: That's not a valid CAN signal- you need a 2v swing. This usually happens when you double terminate. Check to see what the DC R of the converter is and what term is on your board. You might have something like a 30 ohm load.

author: jwet
author_rank: Frequent Contributor
timestamp: September 30, 2022, 07:09:27 am
content: I looked at a CAN USB converter and a cheap CAN module on Amazon. The cheap 3.3v to CAN board has a 100 ohm load term which is a bit stout- this should be 120. If the USB CAN has a 120 ohm load, this would be a 54 ohm load- I don't think that the TI 3.3v Driver can handle that and give you valid CAN. Also check your supplies- if your 3.3v droops to 3v, you won't have the drive.

author: syntax333
author_rank: Regular Contributor
timestamp: September 30, 2022, 08:05:36 am
content: I use Ixxat CAN-USB v2 Converter at the other end. As you said it has no termination resistor as default. I added 120 ohm from CANH to CANL to USB-CAN converter. I plugged the system all together and measured the resistance at CANH and CANL terminals it is 61 ohms. However, the signal is still the same.I got solid 3.3V supply. CAN transceiver module only draws 2mA

author: syntax333
author_rank: Regular Contributor
timestamp: September 30, 2022, 08:56:23 am
content: I checked input signal to CTX pin (MCU->CAN Transceiver) which seems right.Also it is interesting that when I set Rs resistor to 0 ohms and give 500kbps input to transceiver IC it doesn't give an output.

author: jwet
author_rank: Frequent Contributor
timestamp: October 02, 2022, 05:41:26 am
content: I think I'm out of ideas. I've worked with these parts and even defined some in my tenure at Maxim but don't see why they shouldn't work. I looked at a good TI App Note about 3.3v CAN Transceivers design to quell the fear of old 5v CAN guys. Didn't see anything here. You should still get a 1.5v diff min output to the bus required by the receivers. Link to App Note-https://www.ti.com/lit/an/slla337/slla337.pdf?ts=1664628810449&ref_url=https%253A%252F%252Fwww.ti.com%252Fproduct%252FTCAN330G

author: jwet
author_rank: Frequent Contributor
timestamp: October 02, 2022, 05:52:51 am
content: With Rs tied to ground- you should get max slew rate. Something just isn't right. Do you have another '230 board?

author: jwet
author_rank: Frequent Contributor
timestamp: October 02, 2022, 06:12:45 am
content: In looking at your scope trace again, I'm a bit confused. You should be using two channels, one to CAN HI and one to CAN LO. Take you channel grounds to 0V. Is this what you have- only see C1 on the scope.

author: syntax333
author_rank: Regular Contributor
timestamp: October 03, 2022, 09:11:34 am
content: Quote from: jwet on October 02, 2022, 05:41:26 amI totally agree.Quote from: jwet on October 02, 2022, 05:52:51 amJust tried with other module still I get same result. I think I am going to try with other pin compatible CAN transceiver IC like Analog Devices CAN transceivers.Quote from: jwet on October 02, 2022, 06:12:45 amAll channels grounds are at 0V. Sometimes channel markers overlap each other maybe thats why it is not shown in scope.

author: mon2
author_rank: Frequent Contributor
timestamp: October 03, 2022, 11:05:59 am
content: Use your scope probe from channel 2 to confirm it indeed toggles like your channel 1 as shared in your post.

author: jwet
author_rank: Frequent Contributor
timestamp: October 03, 2022, 02:28:49 pm
content: Are you inverting channel 2 and adding on the scope?. Can you put both signal up on the scope as two traces- both signals should sit at the same arbitrary common mode voltage, CAN H should go high by about a volt and CAN L should drop by a volt. The TI app note that I linked has some traces like this. Good luck- I'm going to bow out. Please post what you learn. Sorry I couldn't help you crack it.

author: syntax333
author_rank: Regular Contributor
timestamp: October 03, 2022, 05:38:00 pm
content: Quote from: jwet on October 03, 2022, 02:28:49 pmI am not inverting or "signal processing" in scope or anything.I couldn't find the solution to the problem. Probably IC is dead or fake or something because it is interesting to me that it doesn't draw a current at all. So I changed the IC with SN65HVD234 which works fine. Thanks for all the helps and commnets guys. I am now struggling with other problem. Ixxat CAN transceiver works at 10kbps but as soon as I switch to 500kbps it seems to load the line or something and couldn't receive or transmit anything. I will post details tomorrow.

author: syntax333
author_rank: Regular Contributor
timestamp: October 04, 2022, 05:47:18 am
content: I am using CAN-to-USB v2 converter ixxat module. At 10kbps there is no problem I can transmit and receive message. However, at 500kbps I only get CRC/ transmission error when I try to send data."2.jpg" is when ixxat CAN-to-USB v2 converter is not connected."1.jpg" is when ixxat CAN-to-USB v2 converter is connected.It seems like at high speeds the ixxat module load the line, even the scope cannot decode it. I don't know why. Anyone has any ideas?Edit:I found that the reason that scope cannot decode the data when CAN-to-USB v2 converter is connected is, scope is set to trigger a decode sequence on 2.2V for channel 1. At "1.jpg" you can see that channel 1 never drops below or rises above 2.2V.Datasheet of CAN-to-USBv2:https://www.ixxat.com/docs/librariesprovider8/ixxat-english-new/pc-can-interfaces/manuals-design-guides/usb-to-can-v2-manual-english.pdf?sfvrsn=e1ce4bd7_8

author: syntax333
author_rank: Regular Contributor
timestamp: October 05, 2022, 06:50:39 am
content: Quote from: syntax333 on October 04, 2022, 05:47:18 amSo I found out that there was no problem. I thought CAN peripheral in STM32 would work similar to USART in case of tolerance of baudrate which wasn't the case. I had to program baudrate more precise (max %1 deviation from targeted baudrate). Now the system works. Thanks everybody.

author: darkspr1te
author_rank: Frequent Contributor
timestamp: October 05, 2022, 08:44:07 am
content: Quote from: syntax333 on October 05, 2022, 06:50:39 amIt's buried deep somewhere in STM's doc on the F4xx can system but certain baud rates for can are only possible with certain clock rates too, or at least getting within that 1% requires certain xtal/clock rates. I also recommend that your can bring command be after setup of rates, filters etc as some f4 series chips need it that order or glitches and random stuff occur on the busdarkspr1te