Download the program for the device via the Internet.

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 8.

Moderator: Benj

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

The modules most likely have Weak Pull Ups already installed so you probably don't need to include any. Won't really harm to include though.

These boards only run at +3.3v so do not connect +5v to VCC or Kaboom......

Depending on what you read, the GPIO / Rx pins are +5v tolerant, or not. I have had no issue connecting a microprocessor running at +5v to the modules but if you do not want to take the risk a very simple level shifter can be formed from two resistors. A search for level shifting will throw up many results.

Basic connections are:-

VCC to +3.3v
Gnd to Gnd / 0v
Tx to Rx (uC UART)
Rx to Tx (uC UART)
CH_PD to +3.3v (or uC pin set to High)

With the above connections made you should be able to interact with the module. Depending on your module and the version of firmware it contains things may work straight away without issue or certain instructions may not work as expected. The links I posted earlier will lead you to upgrading to latest versions if you wish.

With the above basic connections you can send commands from a PC or your microcontroller.

The modules to a certain extent are quite "plug-and-play" once you have them setup the way you want. As mentioned the easiest way is to use the USB-TTL Serial converter as you will need to send "AT" commands to verify /change setup (if required).

Using your PC and a terminal program sending the command "AT" should return "OK" if all is good. You can then send further commands to verify / set configurations. Without a PC you will need to program your microcontroller to send instruction, capture the reply and display. I know what I consider to be easier :)

Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good evening! Installed the program CoolTerm.exe ? there seems to be a window from where you can send a command to the esp 8266-01 module and check its performance: like sent the "AT" command, and received "OK". I installed the driver, connected the usb-ttl adapter, inserted the esp 8266-01 module into it, the blue LED blinked, the red LED lit up, made a connection in the program, but for some reason they are not entered (and are not inserted) in the windowteams.
Attachments
the program window.jpg
the program window.jpg (51.65 KiB) Viewed 453 times

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

I'm not familiar with that program but did find a helpful page here

https://learn.sparkfun.com/tutorials/te ... -mac-linux

To check if an adapter is working, connect the Tx pin to the Rx pin. Anything sent will then be returned to you. Once you get that confirmed you can move on to connecting to the module.

Offhand I can't remember the default speed, but I think it was 115200 Baud, not 9600 so try different speeds.

Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! I've tried all the speeds, it doesn't accept anything. Sends yes. There, the program counts down the sent bits. I tried to send via the "send string" menu. Let's delete this program, and install the one you checked. This will make it easier to understand where I'm goofing off... Yes, I connected the Tx and Rx terminals with a wire.

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

This may help

Test Connections.pdf
(315.61 KiB) Downloaded 10 times
Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good evening! Thank you, I did everything as it is written in your instructions (your instructions turned out great, the maestro's hand is immediately visible!) I deleted the program I wrote about earlier because it did not respond to my movements and button presses. I installed another program called terminal v1.9. I entered data in it and tried to send it in the white field at the bottom of the program field, data is sent at all speeds and when you take the esp8266-01 card out of the usb-ttl adapter, nothing changes, so I dare to conclude that I am doing something wrong. I checked the output of CH_PD with a tester, does it have 3.3 volts on it, or should I apply anyway?
Attachments
2.jpg
2.jpg (66.75 KiB) Viewed 428 times
1.jpg
1.jpg (62.67 KiB) Viewed 428 times

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

I think Reset needs to connect to +3.3v too, but as you are measuring that on the pins (Reset / CH_PD) it appears they do have weak pull-ups fitted.

Try with a Baud of 9600 / 38400

I'm quite familiar with the terminal program you are using and from what I see things are correct, but perhaps try the different Baud speeds.

When you connected the Tx of the USB module to the Rx, could you send data and see it returned?

Regards

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

Can you send me a picture of only your esp8266 module, and another of only your USB-TTL serial adapter?

Regards

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

The reason I'm asking for the above pictures is that I'm a bit unsure of your USB / ESP8266 devices. It looks like you may have a "piggy back" USB device that connects to your PC and allows the ESP to just plug in, specifically designed for use with the ESP.

If so, then you would need to first test the USB device without the ESP inserted, with a wire jumper between the Tx and Rx pins of the header that the ESP plugs into.

Pictures of each will make things clear.

Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! Yes, you're right, when I bought the usb-ttl adapter, they said that it was just right to work with the esp8266 -01 module. And I'm going to check it now, as you said, by connecting the Tx and Rx terminals with a jumper. Only I have been using such a terminal program for a very long time and I may not send data correctly
Attachments
USB-TTL adapter for working with the ESP module.JPG
USB-TTL adapter for working with the ESP module.JPG (60.88 KiB) Viewed 414 times
esp8266-01 side view.jpg
esp8266-01 side view.jpg (22.02 KiB) Viewed 414 times
esp8266-01.jpg
esp8266-01.jpg (39.49 KiB) Viewed 414 times

mnf
Valued Contributor
Valued Contributor
Posts: 1189
Joined: Wed May 31, 2017 11:57 am
Has thanked: 70 times
Been thanked: 439 times
Contact:

Re: Download the program for the device via the Internet.

Post by mnf »

I think Iain meant to connect the Tx and Rx pins on the UART-TTL adapter rather than on the esp8266?

Martin

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! I just checked the operation of the usb-ttl adapter. Now I saw how it should work, I previously connected the Rx and Tx terminals with a wire. I tried sending at two speeds - at 115200 baud and then switched to 9600 baud.
Attachments
The USB-TTL adapter is in working condition.jpg
The USB-TTL adapter is in working condition.jpg (63.16 KiB) Viewed 409 times

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! Now I decided to check two esp8266-01 modules.Before checking, I connected the terminals of the RX and Tx module with a wire. The essence of the check was that on one module I sent the number 1 at different speeds, and on the other the number 2. It turned out not a very beautiful picture. That module, where it sent the number 1, often had errors in the entire speed range, except for the speed of 57600 baud. And on the other module, I sent the number 2, also in the entire speed range, and there were no errors anywhere. So we can conclude that the first module is suitable for operation at a certain speed. But maybe flashing it will fix it, I hope so. I would like to know where to go next.
Attachments
send 2 , 1200 baud rate.jpg
send 2 , 1200 baud rate.jpg (62.97 KiB) Viewed 405 times
send 1 , 57600 baud rate.jpg
send 1 , 57600 baud rate.jpg (64.44 KiB) Viewed 405 times
send 1 , 9600 baud rate.jpg
send 1 , 9600 baud rate.jpg (63.55 KiB) Viewed 405 times

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

Good you are seeing something, but not what's expected and I think it's as Martin suggested.

Two quick and easy checks to do.

The first:-
Connect the USB adapter to your PC and open Terminal.
Set Terminal to anything you want (e.g. 9600 Baud, 8-1-N)
Do not insert any ESP8266 module into the adapter socket, leave it empty.
Using a Jumper wire connect the Tx of the socket to the Rx of the socket (no soldering required, just push into the socket).
Click "Connect" in Terminal.
If you have connected everything correctly then anything you type / send in Terminal will be returned to you.

If this does not work then you need to establish why before doing anything else. The above is extremely important and if it is not working then there is no point at all in going forward until it does. If it isn't working then the most likely cause is incorrect connection between Tx and Rx.

When the above is working and only when it is working we can move on to the second test:-

Remove the link between Tx and Rx so that the socket is completely empty.
Insert an ESP8266 module into the adapter socket.
Connect the USB adapter to your PC and open Terminal.
Set Terminal for 115200 Baud and 8-1-N
Click Connect in Terminal

You should now hopefully be connected to the ESP8266

If you type in Terminal
AT <enter> (capital A, capital T, enter/return key)
You should get a reply of
OK

If you do, all is good. If you don't, click Disconnect, change Baud to a different speed, click Connect and try sending AT <enter> again. Depending on your module I would expect the Baud to be either 115200 or 9600 however it really could be anything. The module must return OK when you send AT and if it doesn't then there are problems, most commonly incorrect setting such as Baud.

Only when you get an OK returned can you then begin to interact with the module.

Let me know how you get on.

Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good evening! I already did a check for the usb-ttl module today, when I tested this device, it is functional and data transmission and reception took place. In the near future, I will conduct the following test as you said: connect the esp 8266-01 module to the usb-ttl module (first remove the wire connecting Rx and Tx) and try to send the "AT" command and accept "ok" at different speeds.

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good evening! I checked both modules at different speeds and sent the AT command. It came either AT , or nothing, or some kind of squiggle. "OK" did not come.
Attachments
38400-error.jpg
38400-error.jpg (63.1 KiB) Viewed 365 times
57600 -error.jpg
57600 -error.jpg (62.98 KiB) Viewed 365 times
115200 -error.jpg
115200 -error.jpg (62.56 KiB) Viewed 365 times

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

I will connect up a module of mine and let you know what settings I have, but it seems something isn't correct with your modules / setup.

From what I see in your screenshots it looks like you have the Tx and Rx pins connected as you are seeing "returns" when you send "AT", however as you only see "AT" being returned at one speed, it looks like the USB device is somehow fixed at that speed. The squiggles you mention are typically seen when speeds are incorrect (Terminal set at x-baud but device set at y-baud.

Do you have a link to where you obtained the USB device?

Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! I bought modules at a local radio parts store. And the Rx and Tx pins are no longer connected by wire. You say that by what signals come after sending the command, you assumed that the Rx and Tx pins are connected anyway, I have now checked them in the disconnected state with a tester in different polarities, they are not connected to each other, except that this happens when the program is running when connected to the usb-ttl module.

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

So as to avoid any confusion regarding connections and settings would you do the following quick tests?

With reference to the below .PDF

Test Connections.pdf
(102.17 KiB) Downloaded 6 times

You will see three test scenarios for connecting the ESP8266 and the USB-TTL adapter to your PC.

Test-1 No Connection
Connect your USB Adapter to your PC as per diagram. Your PC should hopefully "Beep" to let you know something has been connected.
Open Terminal
Choose the correct Com Port for the USB Adapter. You may need to ReScan before you see the correct Com Port.
Set the Baud rate to anything you want at 8-1-N (e.g. 9600 8-1-N)
Click Connect
Type anything you wish and press enter a few times
You should NOT see anything being returned to you at all. If you do, then something is wrong and needs to be fixed before moving on.

Test-2 Looped
Connect your USB Adapter to your PC. Your PC should hopefully "Beep" to let you know something has been connected.
Open Terminal
Choose the correct Com Port for the USB Adapter. You may need to ReScan before you see the correct Com Port.
Set the Baud rate to anything you want at 8-1-N (e.g. 9600 8-1-N)
Insert a Jumper Wire to link the Tx and Rx connections as per the diagram.
Click Connect
Type anything you wish and press enter a few times (check CR=CR+LF tick box)
You should see everything you type being returned to you. If you do not then something is wrong and needs to be fixed before moving on. Common issues would include incorrect Com port (try another) or bad connection between Tx and Rx.

Test-3 ESP Inserted
Remove the jumper wire used in Test-2
Insert the ESPP8266 into the USB Adapter
Connect your USB Adapter to your PC. Your PC should hopefully "Beep" to let you know something has been connected.
Open Terminal
Choose the correct Com Port for the USB Adapter. You may need to ReScan before you see the correct Com Port.
Set the Baud rate to 115200 8-1-N (e.g. 115200 8-1-N)
Click Connect
Type anything you wish and press enter a few times (Note: If typing into the "white bar" and then clicking Send, make sure you have ticked the +CR box too).
You should NOT see anything being returned to you. If you do something is wrong.
Type AT and press enter (or click Send if typed in white bar).
You should see OK being returned to you. If not something is wrong.
If you do not see OK being returned when you type AT then try a different speed (9600 etc)

Let me know the results of each test.

Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! I am sending you screenshots after 1 test.
Attachments
test1.jpg
test1.jpg (64.3 KiB) Viewed 229 times

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! I am sending you screenshots after 2 test.
Attachments
test2.jpg
test2.jpg (62.98 KiB) Viewed 229 times

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! I am sending you screenshots after 3 test.
Attachments
test 3.jpg
test 3.jpg (84.69 KiB) Viewed 225 times

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good afternoon! It seems to me that there is some other firmware that does not respond to the "AT" command and most likely you will need to delete the program from the esp 8266 module and download a new one.

chipfryer27
Valued Contributor
Valued Contributor
Posts: 668
Joined: Fri Jun 06, 2014 3:53 pm
Has thanked: 184 times
Been thanked: 204 times
Contact:

Re: Download the program for the device via the Internet.

Post by chipfryer27 »

Hi

Tests 1 and 2 are perfect, your adapter is good.

Your esp seems set at a default speed of 115200 so we will use that.

In your screenshot (test 3) I see that in Terminal you haven't checked the tick boxes for CR=CR+LF (in the settings just above receive window) nor +CR (just left of send button).

Can you tick these and try again at 115200?

Regards

gilanetugila
Posts: 159
Joined: Thu Jul 30, 2020 2:01 pm
Has thanked: 7 times
Contact:

Re: Download the program for the device via the Internet.

Post by gilanetugila »

Good evening! The first time an error message came, and the second and subsequent times it came "AT and OK", I tried at other speeds -some incomprehensible signs come.
Attachments
test3 it seems to be working, showing signs of life.jpg
test3 it seems to be working, showing signs of life.jpg (71.4 KiB) Viewed 190 times
test3 ticked the boxes(CR=CR+LF and +CR).jpg
test3 ticked the boxes(CR=CR+LF and +CR).jpg (68.92 KiB) Viewed 190 times

Post Reply