Arduino untethered? Wireless USB link PC <-> Arduino for programming and serial monitor?

37 views
Skip to first unread message

James H Phelan

unread,
Jun 28, 2024, 10:06:41 AMJun 28
to HomeBrew Robotics Club, Roberto Pensotti

Team,

Has anyone found a solution to cutting the cord between your PC and Arduino?

I failed to meet the TableBot III challenge this week.

This is partly due to my inability to debug the Arduino "in the wild".

What seems to work in "drydock" fails on the table.

I'm unable to see what the Arduino is "thinking" when "untethered".

Adafruit used to have a gadget that looked like it would work, but their chip supply dried up and it's discontinued.  They have multiple wireless gadgets with letters and numbers I don't understand.

There are USB-A bluetooth dongles available for PC (USB-A) (see below).

I've not found a USB-B bluetooth dongle.

There are USB-A to USB-B adapters (also see below).

But will this work with my PCs bluetooth and make a two-way wireless connection from my Arduino IDE to the Arduino on my robot?

Has anyone done this or have another solution to cutting the cord between your PC and Arduino?

Thanks ever so much!

RoverDoc

https://www.amazon.com/TP-Link-Bluetooth-Receiver-Controller-UB500/dp/B09DMP6T22/ref=sr_1_1_sspa?crid=2OORHDEX2V6AJ&dib=eyJ2IjoiMSJ9.zphMgdfoIjRbdIgExwgpjnEXook_xhQsl1ehxP5KX_vKcPhhNCozwVveRNya8xspqFMLDEcbnmM_zrskMsAhA0gUSnsbhqJ5dXWwEh_dxLzNfhpWVu3P_MhjGiwlOLK7KGxxcaGEGbeLdEQKShjs_V8aGcGREoAysZO_aZTYy2pzDKn2sRZHeP6-8VQWOmaR6xs-eFXahG8Hi3I-I24xqy9Mi5laR0jQjSQGBuwBcXU.azakXCIUzfUQUQSjPaMpU6atY3r5-eQzl5xEqEif2m4&dib_tag=se&keywords=usb+bluetooth+adapter+for+pc&qid=1719581988&sprefix=USB+blue%2Caps%2C116&sr=8-1-spons&sp_csd=d2lkZ2V0TmFtZT1zcF9hdGY&psc=1

And USB-A to B adapters such as:

https://www.amazon.com/DTOL-Type-Female-Male-Adapter/dp/B000AA2SMS/ref=sr_1_5?crid=376T90XNK0MMG&dib=eyJ2IjoiMSJ9.05No1lPTAKOIMpZzQXDj6-XXJr42Ua1RbdrxTWL0p2woATFJDbrFkiRW-OhAMWCYsZJkAGeAiPcGDwBYDMbCeoWbqZFtwjNgeIyKc4fS9o-_YjVNbBbX0kA5TQAzXju1HCpBLWL47VOFod1ByYQCYK2k6mQXuipvFWgLxtyyroegnX5kaowQbR-dZzmO-p0TBVfs2vAOFAtbBgZkDpQhYGT_X6IzNjRWHFaHWtw34Hw.8CO_I39PBoTxMwllVqH2SCNtA11jYnBFlSYBcBrhQw4&dib_tag=se&keywords=usb+type+b+female+adapter&qid=1719581927&sprefix=usb+type+b+female%2Caps%2C104&sr=8-5


-- 
James H Phelan
"Nihil est sine ratione cur potius sit quam non sit"
Leibniz

Sergei Grichine

unread,
Jun 28, 2024, 10:20:28 AMJun 28
to hbrob...@googlegroups.com, Roberto Pensotti
I've used BLE-LINK from DFRobot for "serial" communication, including controlling an Arduino robot from an Android phone. Not for programming, although that is advertised. It was a bit of pain in neck, but worked well after all.


They have a module designed for programming: https://wiki.dfrobot.com/Wireless_Programming_Module_For_Arduino__SKU_TEL0037_   (no personal experience here)

DFRobot used to have an Arduino Uno-like with that same BT function built-in.

On Fri, Jun 28, 2024 at 9:06 AM James H Phelan <jhph...@hal-pc.org> wrote:

Team,

Has anyone found a solution to cutting the cord between your PC and Arduino?

I failed to meet the TableBot III challenge this week.

This is partly due to my inability to debug the Arduino "in the wild".

What seems to work in "drydock" fails on the table.

I'm unable to see what the Arduino is "thinking" when "untethered".

Adafruit used to have a gadget that looked like it would work, but their chip supply dried up and it's discontinued.  They have multiple wireless gadgets with letters and numbers I don't understand.

There are USB-A bluetooth dongles available for PC (USB-A) (see below).

I've not found a USB-B bluetooth dongle.

There are USB-A to USB-B adapters (also see below).

But will this work with my PCs bluetooth and make a two-way wireless connection from my Arduino IDE to the Arduino on my robot?

Has anyone done this or have another solution to cutting the cord between your PC and Arduino?

Thanks ever so much!

RoverDoc

--

Best Regards,
-- Sergei

Sergei Grichine

unread,
Jun 28, 2024, 10:31:55 AMJun 28
to hbrob...@googlegroups.com, Roberto Pensotti
https://wiki.dfrobot.com/Bluno_SKU_DFR0267 - this is a wirelessly programmable Arduino Uno from DFRobot

Chris Albertson

unread,
Jun 28, 2024, 11:12:30 AMJun 28
to hbrob...@googlegroups.com, Roberto Pensotti
Are you using an actual Arduino with an Atmel chip?   The simplest thing is a really long cable.

But today in 2024, the Arduino Uno is obsolete.  Try the ESP32.  It will work in the same Arduino IDE and run the same code but the ESP32 is 3X less expensive, 1/2 the physical size, and two orders of magnitude faster.   But the key feature is that it has built-in WiFi and BT.

--
You received this message because you are subscribed to the Google Groups "HomeBrew Robotics Club" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hbrobotics+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/hbrobotics/CA%2BKVXVPWPUU9ep%3DZmww7FuUphqkhBpkm5wScsUDCu-vZYgwVXw%40mail.gmail.com.

camp .

unread,
Jun 28, 2024, 11:39:56 AMJun 28
to hbrob...@googlegroups.com, Roberto Pensotti
> Has anyone found a solution to cutting the cord between your PC and Arduino?

    Yes, they now make Arduinos that include Wi-Fi and Bluetooth.

Arduino Store

- Camp

Gmail

unread,
Jun 28, 2024, 1:10:33 PMJun 28
to hbrob...@googlegroups.com, Roberto Pensotti
I bought one a few months ago, but haven’t tried the wifi. I programmed the LED array through! 



Thomas

-  

Need a great hardworking engineer? I am currently looking for a new job opportunity in robotics and/ or AI. Contact me directly or through LinkedIn:   


On Jun 28, 2024, at 8:39 AM, camp . <ca...@camppeavy.com> wrote:



Chris Albertson

unread,
Jun 28, 2024, 1:39:32 PMJun 28
to hbrob...@googlegroups.com, Roberto Pensotti
Yes this is the way to go. https://store-usa.arduino.cc/products/nano-esp32-with-headers

But they want $21.   You can buy them cheaper on Amazon or even cheaper here: https://www.aliexpress.us/item/3256806270205038.html

If is the same darn part, just without the huge markup.  No matter who you buy these from, they are duel-core 32-bit processors with a few megabytes of memory.   The Arduino library has a web server.   One way to debug is to maintain a web page of internal states.  The libray docs have example code.

The neat thing about dual core is that you can do real-time stuff on one core and interfce stuff on the second core.   And the entire computer costs less than $3.    Why so cheap?  Because these chips are used in huge volume in all kinds of cheap consummer devices.   I have some. light fixtures in my bathroom that have web sites where I can so set-up and configuration.  What chip is inside?  You can bet the manufacturer did not pay for full $2.72 retail price to add the web setup feture to the light.   The CPU is an Open Source RISC-V so they don’t have to pay ARM a royally ir license fee.  RISC-V has 32-bit floating point hardware and some vector instructions and runs two cores at 300+ MHz

While you can use the Arduno IDC to program it, You can also use Micro Python.  It is a lot easier

Even at the official Arduino price of $21 it is a deal, but at under $3, just buy 10 of them at a time.



Nathan Lewis

unread,
Jun 28, 2024, 5:10:45 PMJun 28
to hbrob...@googlegroups.com
Most ESP32 modules are based on the Xtensa LX7 DSP. There are RISC-V variants
available (the "C" and "H" series), but they're all single core and don't
support PSRAM.

There are a boatload of ESP32 variants, to the point it's rather confusing.
I'd recommend using the ESP32-S3 based boards - Dual Xtensa LX7 cores, wifi,
bluetooth, optional PSRAM. Most of the modules you'll find on amazon are the
"classic" dual core Xtensa LX6 version with NO additional ram (the "WROOM"
module).

https://www.espressif.com/en/products/modules

- Nathan
> >> L0037_ (no personal experience here)
> >>
> >> DFRobot used to have an Arduino Uno-like with that same BT function
> >> built-in.
> >>
> >> On Fri, Jun 28, 2024 at 9:06 AM James H Phelan <jhph...@hal-pc.org
> >> <mailto:jhph...@hal-pc.org>> wrote: Team,

Chris Albertson

unread,
Jun 28, 2024, 5:42:32 PMJun 28
to hbrob...@googlegroups.com

There are a boatload of ESP32 variants, to the point it's rather confusing. 
I'd recommend using the ESP32-S3 based boards - Dual Xtensa LX7 cores, wifi, 
bluetooth, optional PSRAM. Most of the modules you'll find on amazon are the 
"classic" dual core Xtensa LX6 version with NO additional ram (the "WROOM" 
module).

Yes, this is all true.  The S3 is the one to get.    But the WROOM module is as said, orders of magnitude more powerful than the classic Arduino, and costs 1/3rd the price and is 1/2 the physical size.  

The even cheaper ESP is so cheap they can afford to put them inside smart lightbulbs.   Who would have thought years ago that every lightbulb could have its own computer inside?

I’d say we live in a Golden Age if we even have to discuss which model of dual-core 32-bit, under $5 computer to use.  Then have you seen the RP2040?  It is perhaps 1/3rd the cost and size of the ESP (but lacks features.)


Sergei Grichine

unread,
Jun 28, 2024, 7:00:30 PMJun 28
to hbrob...@googlegroups.com
While ESP32 are awesome from a hardware and software point of view, there was always a limiting factor for me - low number of GPIO pins. RPi Picos are so much better in this sense. Just don't count on their I2C slave mode operation.

--
You received this message because you are subscribed to the Google Groups "HomeBrew Robotics Club" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hbrobotics+...@googlegroups.com.

Chris Albertson

unread,
Jun 28, 2024, 8:35:12 PMJun 28
to hbrob...@googlegroups.com
I have to agree, I have stacks of both ESP and rp2040 here and I try to use them interchangeably and test code on both microcontrollers.   I can drive 12 or 16 servoes with either part and in both cases get < uSec level timing.   But the RP2040 is 1/3rd the cost and size of the ESP.    

Now that I’m trying to learn about BLDC motors I think my next robot will need 12 motors and each motor will have its own RP2040.    They are so tiny and cheap that it adds almost nothing to the cost or size of a motor driver.

On the other hand the ESP has hardware floating point.  I’d like to use it as the central controller but I might want a Raspberry Pi5.    Who knows there could be a Pi6 before I need to decide.

All that said I still have two of the old Arduino Uno.  They are good for benchtop experimenting with 5V peripheral chips and learning how they work.

Nathaniel Lewis

unread,
Jun 28, 2024, 11:18:11 PMJun 28
to hbrob...@googlegroups.com
Are you using an offboard ADC for current and voltage measurement? Most people seem to be unhappy with the ADC on the RP2040, and you only have 4 inputs either way.

- Nathan

Chris Albertson

unread,
Jun 28, 2024, 11:40:48 PMJun 28
to hbrob...@googlegroups.com
It depends on what you are doing with the ADC.   For low-speed BLDC motors, it seems to work.    That is the criteria, works or not.  For BLDC motor control, timing is very important and the sample has to happen with the PWM pulse is high.

The RP2040 only cost $1 and is 1/4 the size of my thumbnail.    You can afford to use many of these chips.  A dog-robot would need 12 RP2040 chips to control its motors.  There are a lot of open source RP2040-based motor controller designs out there so I doubt I will need to be smart enough to design one.

One thing about RP2040 is that it is nearly impossible to hand solder.  The lead pitch is insanely small., but JLCPCB will do that for free if you buy the chip from them.

For now I’m using ESP32 and RP2040 interchangeably and a rat’s nest of DuPont jumpers and a test stand.  Not an actual robot yet.   

 

Ralph Hipps

unread,
Jul 8, 2024, 10:42:09 AM (10 days ago) Jul 8
to HomeBrew Robotics Club
James,

I have not found a way to add a dongle, etc., to a traditional Arduino and get wireless serial debug or programming to work.

If you are ok with replacing the CPU with one of the options the other folks have suggested that sounds like a good solution. I can't speak to any of those from personal experience but they look promising.

If you would rather not do that and just want to capture serial debug information to review what went wrong, etc., then adding SparkFun OpenLog is a handy solution. It writes your serial output to a micro SD card for later review.

I tested this extensively back in the day and wrote it up in this thread:


links:



Let me know if you have any Qs about it.

Ralph

Mark Womack

unread,
Jul 8, 2024, 11:58:14 AM (10 days ago) Jul 8
to hbrob...@googlegroups.com
I have had luck with remote debugging via WIFI and writing messages to UDP. My ArduinoLogging project (https://github.com/markwomack/ArduinoLogging) allows for UDP to be used 'under the hood' for debug msgs (it defaults to serial for regular use). The robot needs to have WIFI connectivity, which can be built in or auxiliary (like an adafruit AirLift or equivalent esp32 setup). It's been a while since I have done it, but it was invaluable. Obviously, debug messages can't be sent until the WIFI connection is established. (If it's a Teensy 4, I even have a library to handle program OTA updates via UDP. Then it gets really interesting!)

-Mark

--
You received this message because you are subscribed to the Google Groups "HomeBrew Robotics Club" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hbrobotics+...@googlegroups.com.

Michael Wimble

unread,
Jul 8, 2024, 12:26:47 PM (10 days ago) Jul 8
to 'Ross Lunan' via HomeBrew Robotics Club
I use Teensy 4.2 pretty much whenever I need an Arduino device. Besides it been super fast (600MHz) and having tons of pins and RAM, it also has an SD card capability. I wrote a small library to allow me to create a new file (using the next, unused sequential name) and log to that device. It turns out that if you do block writes, it can be very fast to write to the card. Even line by line writes are usually quick enough if you aren’t near the full CPU load on the device. In any logger, you need to be sure you deal with buffer sync so you don’t loose the last line or block of logging data if the software crashes.

James K. Bond

unread,
Jul 10, 2024, 6:16:59 PM (7 days ago) Jul 10
to hbrob...@googlegroups.com, Ralph Hipps
I maybe have, but I've only demonstrated it for myself a couple of times and there are a lot of conditions.

I'm using an HC-05 Bluetooth transmission module I purchased from Jameco (Jameco P/N 2255146, manufacturer Vellerman P/N WPI302). The module might be getting obsolete, although I bought it just a few weeks ago. The module does serial <-> Bluetooth. I'm using an Arduino Mega, which gives me a hardware serial port to run it on, although a software serial port should work. I've only tried using it to display on the Arduino serial monitor--not for programming.

I saw hints of buffering messiness, but haven't used it enough yet to have anything definite.

I'm running the IDE on a recent Mac with current Mac OS. I had trouble initiating the Bluetooth connection. When I got initial failure on my Mac, I tried laptop/Windows and laptop/Linux, also with no luck. What I found by accident was that restarting my Mac would let them connect. Every time I break the connection (power cycle, whatever) I have to restart my Mac. Turning Bluetooth off and back on on the Mac was not sufficient.

I found out about the HC-05 looking at the Arduino website. There are some examples there. A new Arduino, the Giga, is a replacement for the Mega and has a Bluetooth module on board, but I found out after several exchanges with Arduino support, that they are not yet supporting "traditional" Bluetooth, only BLE for now. (The module itself appears to support "traditional" Bluetooth--it's just Arduino not supporting it.)

I specifically wanted Bluetooth and not WiFi because I'm expecting to use the robot out of range of WiFi, and at least at the moment didn't want to complicate the situation creating a local WiFi network.

I don't have a lot of experience with it yet, because as soon as I got it to work a couple of times, I started adding sensors. Miss wired one, and am now in the process of rebuilding a lot of the electronics ;-)
--
You received this message because you are subscribed to the Google Groups "HomeBrew Robotics Club" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hbrobotics+...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages