This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

SCi doesnt work anymore

Other Parts Discussed in Thread: HALCOGEN

Hey guys,
i need a help shortly.
I am using the tms570lc43x on the launchpad XL2.
I want to send some data over the sci interface and it was working the whol time and i dont know why it isn't anymore. Sadly i dont have a second one to check if it is the Mcu.

I am using this chain (ti mcu - ttl/rs232 converter - rs232 straight cable- laptop / terminal hTerm).

i attach the project. can anybody please check if it is working on your controller. please.

maybe something went wrong in halcogen but i cant find anything wrong. (i have a separate header file but it shouldnt make any problems due to i am not using this header). The strange part is, the led is toggleing by pressing the button but the string doesnt come to my terminal.

Thanks for your help.

Best regards
Markus Auer


2273.UartRxTx.zip

  • I downloaded your code and am running it on a launch pad. I don't have SCI3 connected to a transceiver, but am able to run the code. I am wondering about line 157 in the file sys_main.c.

    		while ((UART->FLR & 0x4) == 4);  /* wait until busy */
    

    You are polling the RX IDLE flag before transmitting each character? That really does not make sense for transmission, particularly for full duplex communication to a PC. Is your code getting stuck on this line? If so, try commenting out this line. In the end, your function sciDisplayText() might be replaced by switching the order of the second and third parameters and calling HALCoGen function sciSend() directly.

  • Is the ttl/323 converter for ttl niveau (5V)?
  • @ jan i am using this one :

  • hi bob,

    1) i can also run the code and i get no errors. the problem is that even with breakpoints i can see that the function sciDisplayText tries to send my string mystr="Hello World!". but i dont see it in the terminal program.
    i tried it also with commenting the line 157.

    2) and it can't be the rs232 cable and also not the connector of the laptop because if i try to communicate with an lte module over it i can receive and send something over the terminal.

    3) So it can be only the interface of the hercules board, the pins for sci or the converter. (in my opinion) --> update: i checked it now with a second hercules board and this makes the same result. No text in hTerm and everything else fine. So it seems to be the converter or the settings of halcogen or ccs.

    4) And also something is strange. Sometimes the Error LED (right upper corner abvoe the ethernet connector) is turning on after flashing. Sometimes it turns on after pressing the button, and sometimes if its on it turns off when i press the button.
    What can cause the LED to turn on / off?


  • I checked the product page. It seems to be a device that uses the 5V TTL level. Your Hercules pins are 3.3V tolerant I think.
  • But the ti has on J3 on PIN1 also a 5V Pin. And actually it was working since yesterday morning perfectly.
    (i am not sure if i went to halcogen and pressed on generate code. Due to my less knowledge in halcogen i dont know if there is now an issue because of that.) Because as you can read above the effect comes also on a second hercules board and it can not be the cable or the laptop connector.
    So it can be only a setting / code problem or the converter (in my opinion!)
  • The 5V on J3 is not connected to the microcontroller. It's a power supply pin that you can use to power boosterpacks.

    From the datasheet:

    Input voltage All input pins, with exception of ADC pins –0.3 4.6 V

  • ok. what does it mean exactly?
    because as i said it already worked until yesterday morning. and something went wrong or i dont know what is now the reason for this.
  • It says that the microcontroller takes 4.6V as absolute maximum on input pins. (3.3V is the normal value to be used)
    The RS323/TTL converter that you link to, puts 5V on the SCI input pin. That's above the absolute maximum rating.

  • Markus Auer said:

    ...
    4) And also something is strange. Sometimes the Error LED (right upper corner abvoe the ethernet connector) is turning on after flashing. Sometimes it turns on after pressing the button, and sometimes if its on it turns off when i press the button.
    What can cause the LED to turn on / off?


    Markus,

    for the error LED turning on after flashing, can you check this link?

    These members of the Hercules family have ECC check in memory on always. So the mem has to be correct before it's loaded into flash.

    Regards, Jan 

  • hi jan

    ok i ordered and tested this one:



    and it works!
    But by this one the CTS lamp in hTerm is always on. How is that possible? because this mcu doesnt support cts/rts flow control.

    and can you maybe explain (if you have any clue), why it worked with the converter before for more than 5 weeks and now it didnt?.

  • hi jan,

    yes it helped to replace the "HL_sys_link.cmd" file and make the project settings --> flash settings for the ECC.

    Thanks for that one!
  • Glad it works (both the RS232 converter and the linker command file).
    As long as you supply the converter with 3.3V you're safe, because the logic levels are equal to the supply voltage.

    I have no clue why it doesn't work anymore with the other dongle. It is out of spec for this microcontroller, so it's hard to tell why it acts inconsistent. I think you did the right thing by replacing it.

    CTS/RTS: also no clue :) . I checked the converter's datasheet ( www.nulsom.com/.../NS-RS232_en.pdf ) and the CTS pin is fully in your control. Chances are that it's just wired from the DB9 connector to a breakout pin on the PCB, and not connected to the IC on that PCB.