Connecting Arduino to ARC

Connecting to ARC

On the previous step, we programmed the Arduino to become an EZ-B. Now that the code is running on the chip, we can begin using it with ARC.

  1. Load ARC and press the CONFIG button on the connection control

    User-inserted image

  2. Press the SETTINGS tab and select the BAUD RATE for the EZB Index that will be your Arduino. If you're connecting to multiple devices (i.e. EZ-B v4, IoTiny and Arduino), you will want to have each device on a different connection index. I'm using connection index 0 (zero) in my example. Change the BAUD RATE for the connection index that you wish to use. The BAUD RATE was specified in the previous step. By default, most of the EZ-Arduino firmwares will be 57600 baud.

    User-inserted image

  3. Press SAVE

    User-inserted image

  4. Click on the ADDRESS input of the device index that you configured for the Arduino. In my example, I'm using index 0 (zero). The ADDRESS will display a number of detected addresses and devices, including a COMx port, which is the Arduino. Select the COMx port. My Arduino is on COM6.

    User-inserted image

  5. Now press the CONNECT button and ARC will connect to the Arduino. The capabilities of the particular Arduino device are detected by ARC and displayed in the debug window. In the example below, I added a debug window to demonstrate the connection log.

Notice the capabilities detected by the Firmware used on this Arduino. There are a number of capabilities listed, but there's a larger number of capabilities missing. For example, there is no Video or Audio support. Consult the capability list of the firmware so you understand what features may be missing before using. If a feature is missing from the firmware, ARC will notify you when attempting to use the capability.

User-inserted image

You may now begin using your Arduino with ARC. The port numbers align with the ports of the Arduino. Based on the Arduino hardware version, you may be limited to ports. For example, the Arduino UNO has 14 digital ports and only 2-13 are usable. This is because 0 and 1 are used for the USB. If you select a port higher than 13 in ARC, nothing will happen on the Arduino because there's no port. The same applies to Analog ports, as the UNO only has 6 ADC ports.

The Arduino Mega, however, has enough ports to satisfy ARC’s port selection dialog.


ARC Pro

Upgrade to ARC Pro

Don't limit your robot's potential – subscribe to ARC Pro and transform it into a dynamic, intelligent machine.

#41   — Edited

So, not quite.  If I'm reading that correctly, its flashing the Arduino sketch in that post and then the control plugin is connecting to that Arduino and its sole purpose is to run the ring?  I'm trying to add the neopixel library to the EZ-Mega.ino sketch and run two rings and a strip.  Am I overthinking it, or is that the right path?

***Update. so I added the library in the Arduino sketch, defined the strip, and have the lights animating via the sketch.  I can still connect to the Arduino from ARC so that part isn't broken.  My question now would be, how can I add a new function and call that from ez-script?  I think that will give me what I'm looking for.

***Update 2.   Ok. so I pretty much figured out that I need to add all the custom functionality to the Arduino sketch that I want (in progress), add a custom firmware (https://synthiam.com/Firmware/NewFirmware), add a new version and upload my firmware while also requesting the New Capabilities (https://synthiam.com/Firmware/NewCapability) that I'm adding.  Whew.  Will make the firmware available when (let's be honest, if) I get it finished.

PRO
USA
#42  

Did you see my Happy New Year Mr. Roman robot with Arduino uno -  make sure you click on the icon on the connection  - then go to settings, change the serial connection to 57600

PRO
Synthiam
#43   — Edited

Noggin - i can revisit the neopixel with arduino on a future live hack... I tried it last spring but man, neopixel isn't my favorite. They use A LOT of power and drain batteries super quick. Also, the whole way they work is kinda wacky... the arduino library didn’t work for me in my past live hack. Might be able to find the archived video somewhere on here and see if I made some mistakes that you could fix?

lots of people seem to like the idea of neopixels because of the convenience. Let's see what we can do...

#44  

DJ Sures - Some of your live hacks were taken down with a DCMA request, it appears, but I've watched #4 which got me started on the custom firmware.  I've baked in basic functionality to the Mega sketch, but don't know how to add the EZB Protocol commands on the software side.  I presume thats via the capabilities request, which I put one in last night, but think I did it wrong.  Essentially, if I get all the functions added to the sketch, and provide a list of the new Protocol commands that are needed to call them, can you add those to the app?  We'd need to coordinate on what bytes to send for the commands, but I modeled it after the command/sub command structure I saw.  I can send you a current copy of the firmware if you'd like to see what I was working on.

Let me know!  Feel free to pm me at my profile email address.

United Kingdom
#45  

Should I be able to control the speed at which the servos move when using an arduino? I have tried ServoSpeed and every thing I can think of and the servos still move at full speed. There doesn't appear to be any arduino code supporting CmdSetServoSpeed .

Please help.

PRO
Synthiam
#46   — Edited

Rhfinch - the Arduino ezb firmware does not support the servo speed capability. The list of capabilities for a ezb are displayed in the lower log when connected.

also, the firmware webpage where you downloaded it from has the list of capabilities.

The work around for servo speed is to use the Auto Position control.

United Kingdom
#47  

Thanks. I'll look at that.

Unknown Country
#48   — Edited

Hello need help, i have an excavator project and i want to check with your software, how to start?. The excavator has an arduino mega, esp2866, 2x L298N