Hello there,
I'm trying to set up my mbed as a USB2CAN adapter.
I've made a little program that is able to send a list of messages on regular intervals and I'm working on an addition that makes it possible to compile the messages from data you send from your terminal application.
However, my eventual goal is to be able to link the mbed to CANfestival.
This is an open source program that you can use to easily setup virtual nodes on your PC. It has an Object Dictionary Editor and such, to make it easier.
I want to set up a simple master node on my Ubuntu PC that sends the basic nodeguarding messages. Further more I'd like to be able to read the entire Object Dictionary of the Servomotor I have connected to the mbed canbus.
CANFestival, like the mbed, lets you set the ID, data, length, type and format (msgdata) of a CANmessage and sends it according to protocol. So I'm thinking, once I have a master node set up to transmit through USB to the mbed, I can just stringcopy the message to the mbed canbus somehow?
If string copy doesn't work I'll have to extract the msgdata from the usb transmission somehow and use the mbed to compile a new canmessage out of it.
I want to keep it as simple as possible though.
Are there any tips on how to transfer the USB data to a mbed can message?
Also is there any way of printing the full message through can.read(msg)? So far I'm only able to print the msgdata, but not the whole frame.
I'll post my progress and upload the code once it's done, so other people can use the mbed as an adapter as well!
Thanks in advance for any tips you might have!
Melchior
Hello there,
I'm trying to set up my mbed as a USB2CAN adapter. I've made a little program that is able to send a list of messages on regular intervals and I'm working on an addition that makes it possible to compile the messages from data you send from your terminal application.
However, my eventual goal is to be able to link the mbed to CANfestival. This is an open source program that you can use to easily setup virtual nodes on your PC. It has an Object Dictionary Editor and such, to make it easier.
I want to set up a simple master node on my Ubuntu PC that sends the basic nodeguarding messages. Further more I'd like to be able to read the entire Object Dictionary of the Servomotor I have connected to the mbed canbus.
CANFestival, like the mbed, lets you set the ID, data, length, type and format (msgdata) of a CANmessage and sends it according to protocol. So I'm thinking, once I have a master node set up to transmit through USB to the mbed, I can just stringcopy the message to the mbed canbus somehow?
If string copy doesn't work I'll have to extract the msgdata from the usb transmission somehow and use the mbed to compile a new canmessage out of it.
I want to keep it as simple as possible though.
Are there any tips on how to transfer the USB data to a mbed can message?
Also is there any way of printing the full message through can.read(msg)? So far I'm only able to print the msgdata, but not the whole frame.
I'll post my progress and upload the code once it's done, so other people can use the mbed as an adapter as well!
Thanks in advance for any tips you might have!
Melchior