CAN Bus Library for STM32F103

Can someone help me port this library?
zmemw16
Posts: 1081
Joined: Wed Jul 08, 2015 2:09 pm
Location: St Annes, Lancs,UK

Re: CAN Bus Library for STM32F103

Postby zmemw16 » Fri Dec 16, 2016 9:14 pm

ok i'll bite. where's the car?
stephen

Phono
Posts: 62
Joined: Tue May 05, 2015 6:08 am

Re: CAN Bus Library for STM32F103

Postby Phono » Sun Dec 18, 2016 1:59 pm

@RogerClark: Roger, could you eventually manage with my PR? Will you merge it with the current repository?
I also have ready a thread-safe version of the Ethernet library. Anyone interested?

User avatar
RogerClark
Posts: 5470
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: CAN Bus Library for STM32F103

Postby RogerClark » Sun Dec 18, 2016 9:41 pm

I don't have any CAN bus hardware to test this, nor the time to test it even if I did.

So I've pulled your changes to a separate branch

https://github.com/rogerclarkmelbourne/ ... og-patch-1

So if anyone wants to use them, they can use that branch

michael_l
Posts: 298
Joined: Mon Aug 24, 2015 6:11 pm

Re: CAN Bus Library for STM32F103

Postby michael_l » Mon Dec 19, 2016 7:39 am

Great job! I guess I'll have to try this too. Will order some TJA1050 and try this also. Do PB8 (TX)_PB9 (RX) work also for the blue board ?

Phono: I'd be interested to try your library - if you can create a new branch for that or ?

Phono
Posts: 62
Joined: Tue May 05, 2015 6:08 am

Re: CAN Bus Library for STM32F103

Postby Phono » Mon Dec 19, 2016 7:27 pm

@michael_l
the schematics of the blue pill indicates CAN_RX and CAN_TX for PB8 and PB9, so I do not see why it would not work.
Yes, I will issue a PR for the ethernet library.

And_Ru
Posts: 12
Joined: Thu Nov 10, 2016 1:16 pm

Re: CAN Bus Library for STM32F103

Postby And_Ru » Tue Dec 27, 2016 6:44 pm

I confirm that library works.

Here is the video [youtube]https://www.youtube.com/watch?v=GJgBOnZgmis[/youtube]
Here is thecode:
It sends OK button on my button press and turns on the LED when see "SETTINGS" button is pressed.
I had to add more CAN speed settings into the library, so I've cloned it.

Also there's simple example how to send.

User avatar
Edison517
Posts: 1
Joined: Tue Jan 10, 2017 2:21 am
Location: NC, USA
Contact:

Re: CAN Bus Library for STM32F103

Postby Edison517 » Tue Jan 10, 2017 2:27 am

Hi folks,
I hope I can join in here. I just purchased an STM32F103 Nucelo dev board that I'm going to learn how to use. I come from a few years of Arduino background, tied with CANBUS and I'm hoping to switch over to STM32 since (a few of them) have CAN built in.

When I get my dev board I'll start playing around with it and probably get the CAN library installed and see if I can get it to talk with my 2000 Saab 9-3 bus. I currently have an ATMEGA328P-AU talking via a MCP2515 and a SN65HVD231, so I think I can get things to work with only the 231 chip.

if I figure anything out I can post for others :)
Seth

jongjejung
Posts: 2
Joined: Fri Feb 03, 2017 2:21 am

Re: CAN Bus Library for STM32F103

Postby jongjejung » Fri Feb 03, 2017 2:51 am

@And_Ru : Thank you for your works on this Library. When I tried your simplified sending program to Arduino UNO-MCP 2515,
message sent was good only for firs time then message sending freezes. Have experienced same thing?

bilbolodz
Posts: 2
Joined: Fri Feb 10, 2017 1:04 pm

Re: CAN Bus Library for STM32F103

Postby bilbolodz » Thu Feb 16, 2017 11:08 am

RogerClark wrote:https://github.com/rogerclarkmelbourne/ ... og-patch-1
So if anyone wants to use them, they can use that branch

I know that's not a CAN issue but rather github issue but now, Now Phonog-Phonog-patch-1 is "This branch is 5 commits ahead, 6 commits behind master. " I'm going going to use "Phonog-Phonog-patch-1 branch" but I'd like to use also the new changes from master. Probably I've to fork code into my "private copy" and then commit Phonog-Phonog-patch-1 into it. I'm not very familiar in github so any help will be good idea.

bilbolodz
Posts: 2
Joined: Fri Feb 10, 2017 1:04 pm

Re: CAN Bus Library for STM32F103

Postby bilbolodz » Fri Feb 17, 2017 1:08 pm

OK, I've managed to merge Phonog-Phonog-patch-1 with current sources of Arduino_STM32. In a next few weeks I will try to rewrote my old Arduino MCP2515 project to Arduino_STM32 using OLIMEXINO-STM32 and Olimex SHIELD-LCD16x2. I hope it will work.


Return to “Libary request”

Who is online

Users browsing this forum: No registered users and 1 guest