D
D
Dmitry2015-01-30 21:56:20
Arduino
Dmitry, 2015-01-30 21:56:20

Which interface to choose to control the microcontroller from a computer?

It is necessary to send simple commands from a laptop (abstract self-written application) to the microcontroller to turn on / off the relay. Distance no more than 5 meters.
I see these options:

  • --> USB --> FT232* --> UART - you need to install drivers for FT232, when you plug it into another port, you need to specify a different COM port number in the application
  • Ethernet --> ENC28J60* --> UART
  • Wi-Fi - simple, but at the same time we lose the Internet? And can a PC and MK be connected without an access point?
  • Bluetooth

* - for example, take a ready-made module for Arduino.
What interface, from the point of view of the "grandmother", to "plug in and work" with minimal gestures, would be suitable?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
Armenian Radio, 2015-01-30
@gbg

The first option is more reliable because it does not deal with "network" problems. In addition, if the question is only in controlling the relay while the computer is running, you can get by with one FT232. Port auto-search is about one and a half screens of C++ source code.
Bluetooth is even better as it doesn't tangle the laptop with wires. The HC-05 (Bluetooth<->UART) module is quite common.

T
teleghost, 2015-02-05
@teleghost

if it’s really simple commands to turn on / off the relay, you can also take some industrial module like google: "Ethernet to GPIO", and kick it into the microcontroller ... The industrial one will be less buggy. If "WiFi to GPIO" then it is almost the same as the mentioned WiFi UART TTL radio bridge.
but be careful: as soon as you cross the wires and go into the radio (Bluetooth, WiFi - it doesn’t matter), be very careful about safety. Lock WiFi on WPA2-AES (no WPS), don't leave it for later. In the next 5 years (and beyond, probably), the "Internet of Things" will give rise to a lot of fun vulnerabilities ...

D
Dmitry, 2015-01-31
@Tomasina

and what kind of animal "RS232 radio bridge"? Something like a flash drive with a 433 MHz transmitter?
Another thought is to use the audio output to the headphones. Not speakers + microphone, but a wired connection. The program generates (or plays) the specified sounds or clicks, the controller recognizes them. From the user's point of view, it's generally simple - plug it in and it works, no drivers. But there was no such module.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question