About the CAN controller.

DrSegatron
Posts: 22
Joined: Tue Oct 10, 2017 2:46 pm

Re: About the CAN controller.

Postby DrSegatron » Wed Oct 11, 2017 6:10 pm

Yes that makes sense when you put it that way. Worked here as well, thanks! :D

markwj
Posts: 90
Joined: Tue Mar 08, 2016 5:03 am

Re: About the CAN controller.

Postby markwj » Fri Oct 27, 2017 3:22 am

One other comment; CAN requires at least two devices active on the network in order to operate. Can't transmit without a receiver.

ThomasB
Posts: 38
Joined: Sun Dec 25, 2016 12:11 am

Re: About the CAN controller.

Postby ThomasB » Fri Nov 03, 2017 11:02 pm

Correct. There is some acknowledgement/error check story going on in the ACK slot of the frame. You should get CAN error IRQs if there is no recipent. Haven't tested it.

reneherrero
Posts: 1
Joined: Thu Nov 16, 2017 9:42 pm

Re: About the CAN controller.

Postby reneherrero » Thu Nov 16, 2017 9:46 pm

Hi,

I'm wondering if anyone has tried porting/adapting this to Zephyr OS?

Is this something you guys have in the roadmap?

Thanks,

Rene

cliftonk
Posts: 9
Joined: Sat Jun 10, 2017 8:43 pm

Re: About the CAN controller.

Postby cliftonk » Thu Nov 30, 2017 3:38 am

CAN On ESP32 DevKitC

I’ve been trying to get CAN working on my ESP32 DevKitC for the past few days now--all with NO success.

I’ve successfully built and flashed 2 separate demos without errors. However nothing shows up on the output monitor when I do “make flash monitor”. I also did make flash and then ran “Putty”. The results are always the same—NOTHING on RX, but all other traces are OK and no reboots.

With both demos I configured GPIO4 as RX and GPIO5 as TX. I then connected GPIO4 to GPIO5 with a copper wire. All traced outputs are OK, but nothing comes out on the CAN bus in my traces.

I also configured GPIO35 RX and GPIO5 as TX. I then connected GPIO35 to GPIO5. The boards boots successfully and all the traces are OK, but NO CAN traces show up on the RX line.

I used 2 separate software demos.
1) The first was from ESP32DE/ESP32-CAN-Driver; and
2) The second was from ESP32DE/ESP32-EVB /software/CAN_demo.

Again both demos built OK and flashed OK, but NO traces show up on the RX pin.

I also tried my tests on 2 separate DevKitCs.

Can anyone shed some light?

User avatar
rudi ;-)
Posts: 1729
Joined: Fri Nov 13, 2015 3:25 pm

Re: About the CAN controller.

Postby rudi ;-) » Thu Nov 30, 2017 12:36 pm

cliftonk wrote: Again both demos built OK and flashed OK, but NO traces show up on the RX pin.
hi

do you use on each board a CAN transceiver ( 3.3V or 5V ? which? have you pulled the lines? ) or do you try to measuring the CAN protokoll only by CanRx/CanTx?

can you post a shematic how you have build the DevKitC with your CAN Transceiver on each side?

best wishes
rudi ;-)
-------------------------------------
love it, change it or leave it.
-------------------------------------
問候飛出去的朋友遍全球魯迪

User avatar
rudi ;-)
Posts: 1729
Joined: Fri Nov 13, 2015 3:25 pm

Re: About the CAN controller.

Postby rudi ;-) » Thu Nov 30, 2017 12:49 pm

(append)
btw:
you say you used the demo
have you enabled the test frame to send in menuconfig?

best wishes
rudi ;-)
-------------------------------------
love it, change it or leave it.
-------------------------------------
問候飛出去的朋友遍全球魯迪

cliftonk
Posts: 9
Joined: Sat Jun 10, 2017 8:43 pm

Re: About the CAN controller.

Postby cliftonk » Fri Dec 01, 2017 1:39 am

On the DevKitC, I connected copper wires to the GPIO5 and GPIO4 ports and afterwards to GPIO5 and GPIO35 directly in separate tests.
Do I need to use PULLUPS on the lines?
Do I need to use physical PULLUPS or can I program the DevKitC to PULLUP the respective lines?
(I assumed that the software demos would perform any necessary PULLUPs if they were needed.)
If I need to use physical PULLUPS, what is your recommended resistor value?

Do you have a recommended schematic for the connection?

I recently received a 3.3V CAN transceiver module--VP230 CAN ZDMX.
I wasn't able to find any schematic for this board.

User avatar
rudi ;-)
Posts: 1729
Joined: Fri Nov 13, 2015 3:25 pm

Re: About the CAN controller.

Postby rudi ;-) » Fri Dec 01, 2017 10:10 am

cliftonk wrote:On the DevKitC, I connected copper wires to the GPIO5 and GPIO4 ports and afterwards to GPIO5 and GPIO35 directly in separate tests.
Do I need to use PULLUPS on the lines?
Do I need to use physical PULLUPS or can I program the DevKitC to PULLUP the respective lines?
(I assumed that the software demos would perform any necessary PULLUPs if they were needed.)
If I need to use physical PULLUPS, what is your recommended resistor value?

Do you have a recommended schematic for the connection?

I recently received a 3.3V CAN transceiver module--VP230 CAN ZDMX.
I wasn't able to find any schematic for this board.

can you link to the 3.3V CAN transceiver module--VP230 CAN ZDMX?
is this modul with SN65HVD23x 3.3V ?

you need resistors in the CAN line also perhabs on the modul, you must terminate the CAN Line with resistor in the CAN BUS.
If you use one for transeiver DevKitC and one for receiver DevKitC you must terminate the CAN Bus Lines between with 120 Ohm example.
MCP example ( 5V )



best wishes
rudi ;-)
-------------------------------------
love it, change it or leave it.
-------------------------------------
問候飛出去的朋友遍全球魯迪

cliftonk
Posts: 9
Joined: Sat Jun 10, 2017 8:43 pm

Re: About the CAN controller.

Postby cliftonk » Sat Dec 02, 2017 1:50 am

Hello,

The CAN chip on the CAN board that I have, the VP230, does appear to be a SN65HVD23x 3.3V, when I do a google search.

I did NOT try to connect two ESP32 together via the CAN bus. I only tried to connect the GPIO lines of a single ESP32 together for my tests. I read that shorting GPIO35 (RX) and GPIO5 (TX) should work when the pins are configured as CAN IO pins. Is this correct? Will I need PULLUPS for this?

Who is online

Users browsing this forum: No registered users and 124 guests