Skip to main content
Visitor II
December 26, 2024
Question

Transmitting and Receiving data on STM controller using FTDI from a simulator tool

  • December 26, 2024
  • 1 reply
  • 1145 views

So, I have designed a simple simulator tool for CAN protocol application. So, in that simulator I will be loading the csv file containing some data. This data I have to transmit to CAN bus. I have written a code for CAN transmission, but I am not able to write the UART code to receive the data through the simulator. I am using a FTDI for this so data will be sent through simulator to the controller (STM32F1) and simultaneously the data has to be sent to the CAN so data reception from UART and transmission to CAN should be simultaneous that is in run time

 

    This topic has been closed for replies.

    1 reply

    Technical Moderator
    December 26, 2024

    Hello @Hardware_Enthusiast and welcome to the community.

    Your request is not clear. May be better to draw a sketch on what you want to do..

    Visitor II
    December 26, 2024

    So, I have written a code for simulator whose basic task is load a CSV file which contains some data. Now I have a STM32F1 series controller with me. So now basic approach to send the data to the CAN bus using a controller will be to declare the complete data in a form of array right. But instead of that what I want to do is the simulator that I have developed using python, in that I will load my CSV file. After loading the csv file the data present in the csv file will be sent to the controller using UART communication. So like instead of declaring the data in the form of array in the controller code, I will receive the data from simulator using UART. Now after receiving this data from the UART simultaneously I will send the data towards the CAN bus.

    Screenshot 2024-12-26 174134.png

    Technical Moderator
    December 26, 2024

    Still not clear. 

    Does FTDI has CAN bus interface? Need to provide more information about that FTDI.

    As far as I know FTDI is a bridge/converter between USB and UART not UART to CAN.

    And also the question is not clear: "but I am not able to write the UART code to receive the data through the simulator"

    And what is the relation of that issue with CAN communication. Please be more concise.