Transmit data between UART and Input/OutputPorts on the impee (Arduino and Impee)

I am using the sparkfun example to try finding a way to setup my project, where my arduino runs a screen, etc. So data from web comes in over agent and hands over to device via a JSON object(all working fine). Now I want to set up a serial comm between impee and arduino(nano). I have UART 57 connect to pins D8 and D9, which is not easy to find in the tutorial: pin5-d9 & pin7-d8.

I am impserial printing a “::” string to the IMP code (device) currently but nothing pops up on the imp end.

Now the tutorial might not work on beta, which is my first question, should it?
Second, is the comm only from impee to arduino or works the other way around as well?

PS. there are so many terminologies around the tutorial, its confusing, maybe its worth explaining some basic impee and comms structures a little easier (for dumb folks like me)

I have tried that specific code and it does work. Two things to remember are :
you need to remember to change the serial speed in the serial monitor to 19200 from the default 9600 or else you will get back weird characters or nothing. If you use softserial in arduino i think it does not go more than 9600 so use the RX port on arduino. maybe this helps?

So rather use port 0 and 1 on the arduino?

Yeah I set the baud rate, done that.

@uncleunvoid if your connections are as you have wrote:

“pin5-d9 & pin7-d8”

then it can’t work because are wrong.

According to the imp001 MUX:

http://devwiki.electricimp.com/doku.php?id=imppinmux

with the configuration uart57 the pin 5 is the TX and the pin 7 is the RX. On the Arduino the pin 0&1 are the hardware UART, with D0=RX and D1=TX while D8 is the RX for the serial (virtual) UART and D9 the TX.

So you must connect the TX of imp001 (pin 5) to the RX of Arduino D0 or D8 and the RX of imp001 to the TX from Arduino on D1 or D9.

I would suggest to first try to use the hardware UART on D0/D1 then move to the virtual handled by the software if you are sure the communication is working.

Please don’t forget that Arduino’s GPIOs are based on 5V while the imp can only tollerate 3.3V so you must at least convert from 5V to 3.3V the signal that you receive on pin 7 of the imp001 from pin D1 or D9 on Arduino.

Dimitri

Yes just ordered some logic converters

Okay converters arrived and set up. Looks like I am in the business of transferring data, sort of.
I have it working that arduino can send to imp via impSerial.write() and I can do the same the other way around via hardware.uart12.write();, However so far all I can send is numbers. 0-255 to be precise, then the numbers above sort of start from 0 again. Which means I guess, numbers come in bytes.

So my next step is :
How can I send bigger numbers
OR to be a bit more ambitious,
how do I send bigger chunks of bytes/data back and fro.

Do I do that over an array or string and have to en/decode?
Anyone know where to get that info?

@uncleunvoid

good to know that the hardware is doing well now!

I think you should post a request in the “Software” room to go ahead and I would suggest you to take a look of the previous discussions, devwiki and search the forum for a while, it could be possible you get your answers pretty quick.

Dimitri

Awesome, will do that and my IMPs just started working on our office network. Its a good day!

Thanks smartmaker.

Okay I have it on byte by byte level and had some blob info from some other post, some polishing and voila.

So its about how much data the device or arduino can manage.