Show Posts
Pages: [1]
1  Using Arduino / Networking, Protocols, and Devices / Re: Can I I2C wire two Arduinos with USB cables on both? on: January 29, 2013, 03:27:34 pm
Thanks!

I'll try it! But I think that this means that I'll have to connect pins 0 and 1 from both together (the shield is now only connected via RST, GND, 5V pins 12 to 8 and 13 to 9 to the arduino). No biggie... jumper wires for the job!

Later I tell you what happened... smiley

Edit: It didn't work as well...

But I'm resigned. No big deal. I can always change it with the seeeduino everytime I want to update the soundtable or voice commands...

Thank for your willing to help all the time! I learned so much from here and the manuals!
2  International / Portugues / Re: Easyvr Dormir e Acordar on: January 28, 2013, 03:03:30 pm
Se existe alguém com essa dúvida ainda, é só mandar o caracter 'b' via SoftwareSerial:
Code:
port.write('b'); //port ou como você nomeou a porta serial virtual

Boa sorte! smiley
3  Using Arduino / Networking, Protocols, and Devices / Re: Can I I2C wire two Arduinos with USB cables on both? on: January 28, 2013, 12:14:44 pm
So, I finally got his answer and he sent me these schematics:
https://www.dropbox.com/s/6tk037c5u8g8pz1/EasyVR_Shield_R1D_sch.pdf

I hope that has anything that helps!

Cheers!
4  Using Arduino / Networking, Protocols, and Devices / Re: Can I I2C wire two Arduinos with USB cables on both? on: January 21, 2013, 06:38:52 pm
Quote
And a slave cannot "login" to that bus, it just listens on the bus for commands from the master and replies if it's instructed to do so.
So it's just need to be set as a slave for instructions purposes only! smiley-grin

Quote
Do you know a what baudrate theat EasyVR Commander is communicating with the module?
When at SW bridge mode, the same as the serial monitor:
Code:
 if (bridge.check())
  {
    cli();
    bridge.loop(0, 1, 12, 13);
  }
  // run normally
  Serial.begin(9600);
  //while(!Serial); //for when I need to debug the setup via serial monitor.
  
  port.begin(9600);

  if (!easyvr.detect())
  {
    Serial.println("EasyVR not detected!");
    for (;;);
  }

  easyvr.setPinOutput(EasyVR::IO1, LOW);
  Serial.println("EasyVR detected!");


But from the manual:
Quote
The initial configuration at power on is 9600 baud, 8 bit data, No parity, 1 bit stop. The baud rate can be changed later to operate in the range 9600 - 115200 baud.

When in PC mode, from the manual, again:
Quote
The full speed used is 230400 bit/s, but the option “Slow transfer” can be used to reduce it to 115200, for better compatibility with slower serial adapters2. One adapter that can go to full speed is the SmartVR DevBoard. Otherwise any USB/Serial adapter with TTL/CMOS interface can be used for updating the flash. The EasyVR Shield can be used for the download, provided that the jumper (J12) is in UP position.

Quote
To help you further with this stuff, I need the schematics of the EasyVR shield.
I asked the support guy via email for this, let's see what he replies!

Thanks!
5  Using Arduino / Networking, Protocols, and Devices / Re: arduino + wifi shield + easyVR shield? on: January 21, 2013, 11:59:01 am
I had a similar issue with the EasyVR Shield and Arduino Leonardo. And changed the pins to 8/9 but the shield isn't on top of the Leonardo, but sideways, and  jumperwired the 8/9 of the Arduino to the 12/13 (change the code too). And remember to jumpwire the 5V, GND and Reset between the board and shield also. It will make impossible to use EasyVR Commander or update the soundtable, this last via PC mode.

 The problem is reported here.

This manual is outdated. The latest can be found here:
http://www.veear.eu/downloads/

Be sure to download the latest EasyVR's Arduino library either...

And I didn't see the Brige being used on your code. It should look like this:
Code:
#include "Arduino.h"
  #include "SoftwareSerial.h"
  SoftwareSerial port(8,9);

#include "EasyVR.h"

EasyVR easyvr(port);

EasyVRBridge bridge;

void setup()
{
  // bridge mode?
  if (bridge.check())
  {
    cli();
    bridge.loop(0, 1, 8, 9);
  }
  // run normally
  Serial.begin(9600);
  port.begin(9600);

  if (!easyvr.detect())
  {
    Serial.println("EasyVR not detected!");
    for (;;);
  }

  easyvr.setPinOutput(EasyVR::IO1, LOW);
  Serial.println("EasyVR detected!");
  easyvr.setTimeout(5);
  easyvr.setLanguage(EasyVR::ENGLISH);



If anyone could help me too, would be grateful!
6  Using Arduino / Networking, Protocols, and Devices / Re: Can I I2C wire two Arduinos with USB cables on both? on: January 21, 2013, 11:46:59 am
Quote
If you supply one Arduino, you can just connect the other with GND and 5V pins (on both MCs) and you have power for both. This works if the second Arduino doesn't pull too much power (the RTC is absolutely no problem).

Sharing the 5V between them with USB cables connected to both? Could it be done? Is there some kind of protection as it has when you connect both USB and power supply?

 
Quote
To wich network? In the previous posts you haven't had any network equipment involved. And what does "slave" mean in this context?

I'm sorry, I didn't know how to name it, I meant the I2C "network"...

Quote
Unfortunately there doesn't seem to be any documentation about that shield. The library is fully compatible with the Leonardo, my guess is, the shield is too. At least I couldn't find any specification that would rule against that. Do you have a schematic of the shield (I couldn't find one)? The EasyVR module is completely compatible with the Arduino Leonardo. If the shield isn't done too badly it should be as well.

As I said on the original post for the EasyVR Shield problem: I changed the pins to 8/9 instead of 12/13 and while normal operation it works fine (with some few bugs). But Leonardo can't operate as a brigde between the Shield and the EasyVR Commander app (used to upload, voice commands to the module). Neither in PC mode (there are jumpers in the shield to choose which mode to use), used to upload soundtables, as it was expected, since the Arduino is held in reset just to interface the module thru the USB serial using the default pins (12/13).

The official answer to this question via email is that:
Quote
the leonardo has differences in the pinout.
Please check the following pages where the differences are.

http://arduino.cc/en/Guide/ArduinoLeonardo
http://arduino.cc/en/Reference/Serial

You need to change the pins accordingly.
which didn't get me very far, since there are no explanations about the pin diferences, only that Leo uses Serial1 instead of Serial to connect... I already tried changing on the libs, but without any changes.


Thank you for your constant help!
7  Using Arduino / Networking, Protocols, and Devices / Re: Can I I2C wire two Arduinos with USB cables on both? on: January 18, 2013, 02:43:40 pm
Thank you again!

I've just realised that to have the system working all the time, I will need to have, besides the 2 USB cables for serial communication, 2 power supplies (for when the computer is disconnected). There's anyway that I could use only one PS, say, for the Seeeduino R3, but keeping the features discussed above? (2 USB cables and I2C connection between both and the RTC)

If not, can the Leonardo "login the network" as a slave at anytime, i.e., when the computer starts and be recognized?

I need the Leonardo only to send my Mac keystrokes and shortcuts, for automation with Keyboard Maestro. I wouldn't need one more Arduino unless the EasyVR Shield were compatible with Leonardo. But also it would be great to have the IRRemote and VirtualWire libs running on different Arduinos, since they are incompatible (I think it has something to do with timers) and the workaround was to substitute VirtualWire with MANCHESTER for RF communications (yeah, I have anothers Arduinos receiving commands), which is far inferior than VW.

I hope I'm not asking too much...   smiley-sweat
8  Using Arduino / Networking, Protocols, and Devices / Re: Can I I2C wire two Arduinos with USB cables on both? on: January 18, 2013, 09:11:21 am
Quote
The only other connection needed (besides the SDA and SCL lines) is GND. There's no need to connect the 5V.

OK, I will try it! smiley-grin

Quote
That probably worked because you're using the same computer for the two Arduinos. That way they already share a common ground (over the USB connection). Just because of this you cannot damage your Arduinos.

Good to know. I usually use my Mac Pro connected to my Leonardo and PowerBook to the other when coding, just to don't have to be switching between ports and boards on the Arduino app. Luckly, this time, I was too lazy to turn on the PowerBook and did all in the Mac Pro. I'll be on the safe side next time and ground both together...

I understand that this works with only 2 devices connected. More than this I'll need pull-up resistors connecting SDA and SCL to the 5V. I'm planning, in this setup, to add a I2C RTC to the Leonardo. So, will I need to make a pull-up from the  Leonardo's 5V, anyone or neither? Or this setup won't work at all?

Would you mind to share your source of information? I want to learn more about I2C from a complete source (I went crazy yesterday seeking for this information).

And how do I +Karma you? I can't see any button here for this...

Thanks a lot!
9  Using Arduino / Installation & Troubleshooting / Could anyone make EasyVR work with Arduino Leonardo? on: January 17, 2013, 06:58:28 pm
Hi!

I have a Leonardo and an EasyVR Shield (manual here). The default RX/TX pins for this shield are 12/13. I made a pretty complex room automation sketch to work with it, but, since I needed to be switching jumpers on the shield to upload voice commands to it, I did all the code on a Seeeduino R3. It all worked fine there. When I switched to the Leonardo and uploaded my code to it, nothing happened. Then I've found that my mistake when trying to watch the serial monitor was to forget to place this line:
Code:
while(!Serial);

By doing this I got the "EasyVR not detected!" serial feedback...

Changing the approach to connect Leonardo with the shield I did this:

Trying to upload the code with the shield detached and with the pins 12 and 13 of the shield jump wired to the arduino pins 8 and 9 (using them as RX/TX) and changing both references for them on the sketch. I also jump wired the GND, 5V and Reset to the shield's equivalents. I've got it uploaded, but always with these warnings:

Code:
Binary sketch size: 22.118 bytes (of a 28.672 byte maximum)

processing.app.SerialException: Serial port '/dev/tty.usbmodemfd541' already in use. Try quitting any programs that may be using it.
at processing.app.Serial.touchPort(Serial.java:119)
at processing.app.debug.AvrdudeUploader.uploadViaBootloader(AvrdudeUploader.java:201)
at processing.app.debug.AvrdudeUploader.uploadUsingPreferences(AvrdudeUploader.java:67)
at processing.app.Sketch.upload(Sketch.java:1671)
at processing.app.Sketch.exportApplet(Sketch.java:1627)
at processing.app.Sketch.exportApplet(Sketch.java:1599)
at processing.app.Editor$DefaultExportHandler.run(Editor.java:2380)
at java.lang.Thread.run(Thread.java:680)



The sketch works, but buggy and sometimes it crashes. Can it be fixed?

Does anyone knows why it didn't work with pins 12 and 13?


Thank you!
10  International / Portugues / Re: Easyvr Dormir e Acordar on: January 17, 2013, 05:06:23 pm
Até onde eu saiba, ele só pode "acordar" com palmas (claps), assovio (whistle), um som alto ou com um caractere recebido via serial.

Boa sorte!
11  Using Arduino / Networking, Protocols, and Devices / Can I I2C wire two Arduinos with USB cables on both? on: January 17, 2013, 04:58:00 pm
Hi!

It's my first topic here and I spent the day searching on the web for it: I have 2 Arduinos (Seeduino R3 and Arduino Leonardo) that needs to be connected together via I2C but at the same time both via USB serial to the computer. And I never have seen such a thing.

My questions are:

1. Will it work, since both need to share the 5V and GND and both are with their own power supply (via USB)? I didn't try it just because I think it can harm the boards.

2. I tried to just connect the two cables for SCL and SDA without the 5V and GND and it all went fine when running the wire lib skecthes. Will it work on a long run or with a more complex program? Could this damage my Arduinos in anyway?

Anyone can help me?

Thank you,  smiley-wink

Mario
Pages: [1]