Author Topic: Touch screen for input selection  (Read 3803 times)

0 Members and 1 Guest are viewing this topic.

Offline Barnys1

  • Newbie
  • Posts: 4
  • Country: england
Touch screen for input selection
« on: September 23, 2016, 11:38:57 am »
Hi
I am a first time poster, a little skilled but have the time to try, try, and try again...

I have been trying to figure out....
In a DIY project, how would I create a system where a touch screen can be used to control things like audio inputs – outputs?
E.g. if there are two inputs, one going to two outputs and the other going to a singly output, then with a touch screen be able to rearrange which input goes where, how would that work?

I have been asking lord google but getting nowhere, so any ideas, points and/or even component suggestions are welcome.
 
Regards.
« Last Edit: September 23, 2016, 11:43:39 am by Barnys1 »
 

Online Marco

  • Super Contributor
  • ***
  • Posts: 4463
  • Country: nl
Re: Touch screen for input selection
« Reply #1 on: September 23, 2016, 01:05:23 pm »
Do you have an old android mobile phone lying around by chance?

You can connect it to say a TI Launchpad. Do the electronic interfacing on the Launchpad and the GUI on the Android phone.
 

Online MarkF

  • Super Contributor
  • ***
  • Posts: 1411
  • Country: us
Re: Touch screen for input selection
« Reply #2 on: September 23, 2016, 11:21:44 pm »
Touch screens have a serial or USB interface the to read the x/y location that was touched.  You define an area of the screen for a button, draw the button and then check that area for a touch.  Some times you can get a driver that will translate the touches into a curser input. Then you just process mouse inputs.
« Last Edit: September 23, 2016, 11:23:25 pm by MarkF »
 

Offline FreddyVictor

  • Regular Contributor
  • *
  • Posts: 164
  • Country: gb
Re: Touch screen for input selection
« Reply #3 on: September 24, 2016, 08:26:05 am »
To add to MarkF's answer, the switching of the actual inputs/outputs for audio would typically be done using relays

example Pre-amp project by Mark Hennessy
 

Offline Barnys1

  • Newbie
  • Posts: 4
  • Country: england
Re: Touch screen for input selection
« Reply #4 on: October 03, 2016, 02:39:34 pm »
Hi

Thanks for the replies.

I don’t have a smart phone that can be used for this but I have (tentatively) been investigating a potential Arduino/ Launchpad/ Raspberry PI etc solution.  They “appear” to be a likely option.  I am thinking I will need 8 output pins to switch the relays, does anyone know if an Arduino etc touch screen setup would have enough pins available for the pin-relay switching and screen connection?

Relays.
I am currently leaning toward a nominal 5 volt DTDP latching style of relay.  My reasoning is simply that I have 5V available, DPDT means fewer relays and self latching appeals because it removes the need to always have each active relays coil energised.  I am thinking of trying 4 relays so I can run 2 separate unbalanced stereo inputs with both being able to independently switch to 2 separate outputs.     
Zettler AZ832P2–2C–5DE, 5V     http://www.azettler.com/pdfs/az832p.pdf     
HONGFA HFD3/5-L2S1R,   4.5V    http://www.azettler.com/pdfs/az832p.pdf   

What about relay minimum contactor load, as far as I can tell the Zettler doesn’t state a minimum load but the Hongfa is classed as a Signal Relay with a contactor minimum listed as 10mV and 10 micro amps (I have been trying to read data sheets   :)).  How critical is a minimum contactor load, would the Zettler serve my purpose?  I am having trouble finding suitable relays, there are lots of non latching single pole options but very few DPDT latching types (that is if I don’t want to buy 20 or more of them).  Also, is contactor bounce an issue, when dealing with such small current values?

Connecting the relays.
I have seen some (expensive) premade multi relay units labelled as “passive” with only one diode per relay coil.  Alternatively I have seen a lot of examples with many being labelled “for Arduino etc” applications where each relays set (and reset) functions are switched via circuit using transistor(s), resistor(s) and diode and what I think is an optocoupler, alternatively I have seen discussions suggesting a circuit looking similar to this:   


So, why are some assembled relay boards labelled as passive?  Is it because they don’t have active components (e.g. transistor) connected?
Since my choice of relay type means I may have to assemble the relay board, what is the expert opinion about each relays associated circuit, is the type linked to above acceptable or is it better to use something like the optocoupler versions, e.g. 3:42 and 8 mins         

Regards.
 

Online MarkF

  • Super Contributor
  • ***
  • Posts: 1411
  • Country: us
Re: Touch screen for input selection
« Reply #5 on: October 03, 2016, 08:21:16 pm »
Latching relays sound like a lot of expense to save a little current.
I would suggest an arduino shield with relays and a small touch panel.
http://www.arduino.org/products/shields/arduino-4-relays-shield
https://www.adafruit.com/products/2050
 

Offline cncjerry

  • Supporter
  • ****
  • Posts: 946
Re: Touch screen for input selection
« Reply #6 on: October 04, 2016, 04:46:03 am »
Latching relays are good for maintaining the status when power is off.  If you plan to have this thing under power then it isn't worth the expense as others pointed out.  You can use EEPROM to maintain power on/off status.  I use relays for things like this and using an arduino shield you can integrate touch screen, wireless, Bluetooth, Ethernet, just about everything even IR control for cheap.
 

Offline FreddyVictor

  • Regular Contributor
  • *
  • Posts: 164
  • Country: gb
Re: Touch screen for input selection
« Reply #7 on: October 04, 2016, 07:32:38 am »
I am thinking I will need 8 output pins to switch the relays, does anyone know if an Arduino etc touch screen setup would have enough pins available for the pin-relay switching and screen connection?

It could be a little tight, may depend on the exact display you use, the cheap ILI934x ones on ebay typically use SPI for both the display and the touchscreen
For the relays, you can use 74HC5951 coupled with ULN2803/20031 which allow 8/7 relays (but can be daisy-chained for more relays) to be controlled using just 3 pins using SPI (can bit-bang so any pin can be used)
The ULN2xxx have inbuilt diodes so are ideal
*1. other members on this forum may have better options ?
 

Offline Barnys1

  • Newbie
  • Posts: 4
  • Country: england
Re: Touch screen for input selection
« Reply #8 on: October 09, 2016, 12:49:05 pm »
Thanks again for the replies.

I chose DTDP relays because the unit will be powered down and I want it to maintain whatever the previous setting was.  Also, I want to switch audio input signals and thought it would be better if the switched relays coils were not continually energised.

FreddyVictor
Please correct me if I have this wrong, but as I understand the 74HC595 application the chip allows for multiple switches from each Arduino pin and not an increase in number of unique switches available.


Is this possible with an Arduino-relay solution; is there a better way to achieve my goal of being able to use a touch screen to control the destination of multiple audio inputs?
E.g.  there are two (or 3, or 4...) inputs and two (or 3 etc) outputs, I want to be able to choose which outputs each input goes to.  Theoretically input one can go to 1, 2 or all of the outputs, alternatively it could be isolated (no outputs) and the same for input 2, 3...

Regards
 

Offline FreddyVictor

  • Regular Contributor
  • *
  • Posts: 164
  • Country: gb
Re: Touch screen for input selection
« Reply #9 on: October 09, 2016, 03:47:21 pm »
FreddyVictor
Please correct me if I have this wrong, but as I understand the 74HC595 application the chip allows for multiple switches from each Arduino pin and not an increase in number of unique switches available.
See this page
In 1st color picture, they have arduino connected to ULN2803 controlling multiple relays but needing same number of pins on arduino as relays
Later on they insert 74HC595 between arduino + ULN2803 so they only need 3 control pins from arduino to control up to 8 relays
This picture shows the 74HC595's daisy-chained together to control 16, but any number can be connected.
On the 74HC595, the DS pin is the Serial-Input pin and the Q7 pin the Serial-Output which is connected to the following 74HC595 etc

Is this possible with an Arduino-relay solution; is there a better way to achieve my goal of being able to use a touch screen to control the destination of multiple audio inputs?
E.g.  there are two (or 3, or 4...) inputs and two (or 3 etc) outputs, I want to be able to choose which outputs each input goes to.  Theoretically input one can go to 1, 2 or all of the outputs, alternatively it could be isolated (no outputs) and the same for input 2, 3...

Yes, every output must have a relay connecting it to every possible input, so, the number of relays required could get quite high depending on how many inputs/outputs you have !
 

Online MarkF

  • Super Contributor
  • ***
  • Posts: 1411
  • Country: us
Re: Touch screen for input selection
« Reply #10 on: October 09, 2016, 11:32:17 pm »
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf