View previous topic :: View next topic |
Author |
Message |
Zek_De
Joined: 13 Aug 2016 Posts: 100
|
pic18f4550and FTDI problem.Terminal doesn't transmit to FTDI |
Posted: Wed May 23, 2018 2:02 am |
|
|
Hi friends ,I encountered a problem with serial terminal and ftdi.Let me explain.
pic18f4550 is sending data to Ftdi and Ftdi is sending this data to serial terminal and I can see data, but I couldn't manage to send data to Ftdi from serial terminal.If I try with ESP8266(this is module with usb) I can send AT and I receive OK also I can see my data on terminal that I want to send ,but if I try with ftdi, pic18f4550,when I try to enter any key on keyboard I can see led activity on FTDI but there is no any command on terminal and pic18f4550 doesn't receive any command from terminal. |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19539
|
|
Posted: Wed May 23, 2018 2:16 am |
|
|
You don't actually give us enough to really help. FTDI is a chip manufacturer they do hundreds of different configurations. However one thing is 'screaming' at me. The ESP8266 module is a 3.3v device. As such it cannot connect directly to a PIC8F4550 without a level translator.
Quote: |
The ESP8266’s maximum voltage is 3.6V, so the thing has an onboard 3.3V regulator to deliver a safe, consistent voltage to the IC. That means the ESP8266’s I/O pins also run at 3.3V, you’ll need to Logic Level Controller any 5V signals running into the IC.
|
FTDI do modules that have TTL outputs, 3.3v outputs and RS232 outputs. Only the TTL (5v) ones will work with your PIC.
So this one:
<https://uk.rs-online.com/web/p/products/0429278/?grossPrice=Y&cm_mmc=UK-PLA-DS3A-_-google-_-PLA_UK_EN_Semiconductors-_-Semiconductor_Development_Kits%7CInterface_Development_Kits-_-PRODUCT+GROUP&matchtype=&gclid=EAIaIQobChMI__HC_Lqb2wIVQZztCh3c3wVNEAQYAiABEgIfT_D_BwE&gclsrc=aw.ds>
will work.
But this one:
<https://uk.rs-online.com/web/p/products/6877825/?grossPrice=Y&cm_mmc=UK-PLA-DS3A-_-google-_-PLA_UK_EN_Semiconductors-_-Semiconductor_Development_Kits%7CInterface_Development_Kits-_-PRODUCT+GROUP&matchtype=&gclid=EAIaIQobChMI__HC_Lqb2wIVQZztCh3c3wVNEAQYAyABEgKHmPD_BwE&gclsrc=aw.ds>
Won't.... |
|
|
Zek_De
Joined: 13 Aug 2016 Posts: 100
|
|
Posted: Wed May 23, 2018 4:47 am |
|
|
I mean FTDI USB to Serial converter . I will tell step by step
First, I tried to communicate ESP8266 module including USB and I send some AT command in it and it worked.I mean I managed to send command with serial terminal.I could see my command on serial terminal and my device is nodemcu.
Secondly,I tried first serial terminal - pic - ftdi before I don't connect an other ESP8266(other version not nodemcu just include 8 pin) and I couldn't manage to send data to ftdi from serial terminal but I can get data from pic-->ftdi--> terminal.I cant send data terminal --> ftdi --> pic.And I couldn't see any command on terminal when I press the keyboard,but led is blinkink when I press the keyboard.Where is the problem |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9243 Location: Greensville,Ontario
|
|
Posted: Wed May 23, 2018 6:49 am |
|
|
OK, I'll try to help.
Since that PIC has USB internal ,are you using it OR and EXTERNAL USB<>TTL module ? It sounds like you're using an external FTDI module.
BUT, there are several versions.
IF you're connecting PIC to PC, you'll need a USB<>TTL module NOT a USB<>RS232 module.
Also what voltage are you running, 5V or 3V ? Some PICs won't run at high speed on low voltage.the 4550 has a MINIMUM of 4.2 V, if my memory serves me right, so it will not run at 3V, which is typical voltage for external peripherals these days.
simple tests
1) connect USB module to PC, wire TXD and RXD together. run terminal program. every PC keypress should be displayed on PC screen.
2) now connect TXD to RXD of PIC, and RXD to TXD of PIC. run a simple 'echo' program on the PIC(CCS supplies an example ). Now every PC keypress should be seen on PC screen. IF not, show us your 'echo' program.
hope this helps
Jay |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19539
|
|
Posted: Wed May 23, 2018 6:54 am |
|
|
My comments about the different types of FTDI modules totally apply. Only a USB to TTL module will work. The other types they do (RS232, RS485 etc.), won't.
You need the type number of your FTDI module, & preferable who supplied it. |
|
|
Zek_De
Joined: 13 Aug 2016 Posts: 100
|
|
Posted: Wed May 23, 2018 8:14 am |
|
|
Friends firstly thank you information. I tried another terminal program called hyper terminal and I did a small change, files-->options--> settings --> ascii settings and I set a thing to show me my writing. And I got a feedback and it works but earlier why didn't it work, I dont know but it works now. Thank you again. |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9243 Location: Greensville,Ontario
|
|
Posted: Wed May 23, 2018 9:12 am |
|
|
Glad to hear it's working...
FWIW I've used 'RealTerm' for several years. It has a lot of easy to use options and seems 'stable'.
Jay |
|
|
|