Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Login


Options
View
Go to last post Go to first unread
billbixbeed  
#1 Posted : Thursday, May 9, 2013 3:24:21 AM(UTC)
billbixbeed

Rank: Member

Groups: Member
Joined: 3/21/2013(UTC)
Posts: 3
Location: NYC

Hi,
I have been wanting to get an Arduino up and running for a long time, and I finally got the job done today, thanks to GLT and his hifiduino site. It is still in prototype mode, and needs some tweaking, but it is working.

My setup is a MUX i2s and an Amanero USB-i2s into an OTTO and the output of the OTTO into a Buffalo II.

I would like to be able to use the Arduino to switch the OTTO and the MUX, so that when I switch inputs it automatically switches the OTTO and the MUX to the appropriate input. Does anyone have any working code for either? It would be great to be able to see how someone else did it before I go and try to hack my own (I know some Python and Java, but no C). I tried searching, but didn't find anything here, or on github, but I might not have searched correctly.

Thank you for taking the time to read my post.
Moritz  
#2 Posted : Saturday, May 11, 2013 6:56:02 PM(UTC)
Moritz

Rank: Member

Groups: Member
Joined: 3/9/2013(UTC)
Posts: 2
Denmark
Location: Copenhagen

Thanks: 1 times
Hi i think that www.ce-designs.net has implementet otto control. You will find it under download.
DQ828  
#3 Posted : Sunday, May 12, 2013 11:27:52 AM(UTC)
DQ828

Rank: Member

Groups: Member
Joined: 8/17/2010(UTC)
Posts: 368
Location: australia

Thanks: 8 times
Was thanked: 3 time(s) in 3 post(s)
I am just using a relay to switch the OTTO as per the setup below, Russ say you can switch without the relay but I and others had issues with that so I just stayed with the relay, its simple & also helps isolate the BIII from the Arduino.

All you need to do is send the relay High & Low to switch. If you need any help with the code let me know.

UserPostedImage

Edited by user Sunday, May 12, 2013 11:29:33 AM(UTC)  | Reason: Not specified

Russ White  
#4 Posted : Sunday, May 12, 2013 7:50:03 PM(UTC)
Russ White

Rank: Administration

Groups: Administration, Customer
Joined: 10/24/2006(UTC)
Posts: 3,979
Location: Nashville, TN

Thanks: 25 times
Was thanked: 89 time(s) in 83 post(s)
if you use a 10K pull down on S you won't have any issue using a controller directly.

The relay is not at all necessary - but it certainly doesn't hurt anything.
billbixbeed  
#5 Posted : Thursday, May 16, 2013 1:25:06 AM(UTC)
billbixbeed

Rank: Member

Groups: Member
Joined: 3/21/2013(UTC)
Posts: 3
Location: NYC

Hi Russ,
Where do I put the resistor when using OTTO S - level converter - Arduino digital pin for control?

I did a bit of practice work with the Arduino code and figured out how to change it to work with the OTTO and MUX with the hifiduino code. Now I just have to get the white apple remote I have to work with all of it's buttons.

I was able to change the code to get the MUX and the OTTO hooked up and working so that they switch with the input changes with the hifiduino code. I am using a 5 volt to 3.3 volt level converter (same one I am using for the i2c connection for the buffalo II) to connect the OTTO, and direct 5 volts for the MUX.

My setup is the 4/1 MUX to i2s into OTTO, an Amanero USB i2s into OTTO, and OTTO into Buffalo II.

Here is how I modified the code, in case someone else wants to do this as well. Hopefully this will help. Line numbers are tricky in the Arduino IDE. To find the line number, look at the bottom. The line number of the cursor is displayed.

I decided to use analog pins A0, A1, and A2 on the Arduino Uno to control the OTTO and the MUX. Two pins for the MUX, and one for the OTTO. They can also be used as digital pins 14, 15, and 16 respectively. I connected pins 14 and 15 to MUX control 0 and 1, and pin 16 to the 5 volt side of the level converter, and the 3.3 volt side to OTTO S. I also connected the GND connection on the MUX control to the GND on the Arduino.

At line 1220, I added code to make the analog pins digital output pins on the arduino.

pinMode(14, OUTPUT)
pinMode(15, OUTPUT)
pinMode(16, OUTPUT)


Then under each input, I set the pins to LOW or HIGH so that the correct input would be selected. On HIGH, the pin outputs 5 volts. On LOW, the pin outputs close to 0 volts. Testing the circuit with LCD's confirmed that the once a pin is set to HIGH or LOW, it will stay there unless it is told to change on the following input. I made sure to turn off pins that I did not need on for each input. Here is how I modified the code to turn the pins on and off to switch the MUX and OTTO.

The digitalWrite() lines are the ones that I added. The first two inputs set the OTTO to output the Amanero. The third sets the OTTO to the side with the MUX, and selects input 1 on the MUX. Then input 2, then 3, then back to the Amanero again.

case 0:
lcd.print(no0);
digitalWrite(16, LOW);
break;
case 1:
lcd.print(no1);
digitalWrite(16, LOW);
break;
case 2:
lcd.print(no2);
digitalWrite(16, HIGH);
digitalWrite(14, LOW);
digitalWrite(15, LOW);
break;
case 3:
lcd.print(no3);
digitalWrite(16, HIGH);
digitalWrite(14, HIGH);
digitalWrite(15, LOW);
break;
case 4:
lcd.print(no4);
digitalWrite(16, HIGH);
digitalWrite(14, LOW);
digitalWrite(15, HIGH);
break;
case 5:
lcd.print(no5);
digitalWrite(16, LOW);
digitalWrite(15, LOW);
digitalWrite(14, LOW);
break;

Edited by user Thursday, May 16, 2013 2:48:45 AM(UTC)  | Reason: added that I connected GND from MUX control to arduino

Russ White  
#6 Posted : Thursday, May 16, 2013 2:59:41 AM(UTC)
Russ White

Rank: Administration

Groups: Administration, Customer
Joined: 10/24/2006(UTC)
Posts: 3,979
Location: Nashville, TN

Thanks: 25 times
Was thanked: 89 time(s) in 83 post(s)
There are pads on the OTTO_II near "S" - one to VCC and one to GND. Place a 10K resistor from "S" to GND.

Now the OTTOn "S" pin will be solidly pulled low until your controller drives it high (no higher than OTTO VCC)
billbixbeed  
#7 Posted : Thursday, May 16, 2013 3:10:31 AM(UTC)
billbixbeed

Rank: Member

Groups: Member
Joined: 3/21/2013(UTC)
Posts: 3
Location: NYC

Thanks Russ! I will add the resistor. I already had one installed differently when I had an analog switch for the OTTO.

DQ828  
#8 Posted : Saturday, March 7, 2015 11:58:47 PM(UTC)
DQ828

Rank: Member

Groups: Member
Joined: 8/17/2010(UTC)
Posts: 368
Location: australia

Thanks: 8 times
Was thanked: 3 time(s) in 3 post(s)
I'm doing some mods & want to loose the relay but also want to be sure I've got this right.

It is my understanding from what I have read that;

* I have a 10k resistor between S & GRND
* I have a 10k resistor between S & VCC
* I have a link between OE & Grnd
* I drive S High & Low with Arduino

Is that correct?

http://i1118.photobucket...Question_zpsqqm5fpr5.jpg

Edited by user Sunday, March 8, 2015 12:02:00 AM(UTC)  | Reason: Not specified

DQ828 attached the following image(s):
Otto Control Question.JPG (81kb) downloaded 14 time(s).

You cannot view/download attachments. Try to login or register.
DQ828  
#9 Posted : Tuesday, March 10, 2015 2:14:09 AM(UTC)
DQ828

Rank: Member

Groups: Member
Joined: 8/17/2010(UTC)
Posts: 368
Location: australia

Thanks: 8 times
Was thanked: 3 time(s) in 3 post(s)
Originally Posted by: DQ828 Go to Quoted Post
I'm doing some mods & want to loose the relay but also want to be sure I've got this right.

It is my understanding from what I have read that;

* I have a 10k resistor between S & GRND
* I have a 10k resistor between S & VCC
* I have a link between OE & Grnd
* I drive S High & Low with Arduino

Is that correct?

http://i1118.photobucket...Question_zpsqqm5fpr5.jpg


Any thoughts?

Tostaki  
#10 Posted : Wednesday, March 18, 2015 10:06:48 AM(UTC)
Tostaki

Rank: Member

Groups: Member
Joined: 7/18/2012(UTC)
Posts: 26

Thanks: 1 times
Was thanked: 3 time(s) in 2 post(s)
Hi DQ828,

This is unclear to me why you want a pull-up && a pull-down of the S pin.
With a shared GND between your arduino & the Otto board, you should be able to drive the Otto from one Arduino pin (this is the dirty way)
To make things properly, a simple pull-up or pull-down should be enough. This is to chosse the default state of the pin.

I am using a relay to drive the board. To remove it, I would use a pull-up (1k probably to get sharper response).

Here a code snippet : https://codebender.cc/sketch:95185
Tostaki  
#11 Posted : Friday, March 20, 2015 10:56:28 AM(UTC)
Tostaki

Rank: Member

Groups: Member
Joined: 7/18/2012(UTC)
Posts: 26

Thanks: 1 times
Was thanked: 3 time(s) in 2 post(s)
Originally Posted by: DQ828 Go to Quoted Post
Originally Posted by: DQ828 Go to Quoted Post
I'm doing some mods & want to loose the relay but also want to be sure I've got this right.

It is my understanding from what I have read that;

* I have a 10k resistor between S & GRND
* I have a 10k resistor between S & VCC
* I have a link between OE & Grnd
* I drive S High & Low with Arduino

Is that correct?

http://i1118.photobucket...Question_zpsqqm5fpr5.jpg


Any thoughts?



Hi DQ828,

I suggest using either pull-up or pull-down resistors, not both as it will result in a /2 voltage divider and a "floating" reference.
Using some 1K resistors may provide sharper transitions.

Here a code snippet to use with Otto Board https://codebender.cc/sketch:95185

Rss Feed  Atom Feed
Users browsing this topic
GuestUser (3)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.