Silly question - Page 1
Forum section: electronics / beginners

author: Rigby
author_rank: Super Contributor
timestamp: April 12, 2014, 01:49:40 am
content: this is going to sound particularly stupid, maybe. It sounds stupid in my head, anyway.I have desks at work which change their height via a micro and motor controller combination, with position feedback on each leg. this particular desk is a 2-leg setup.Ultimately I want to replace the micro and motor controller with something of my own design, so that I can control the desk from my PC, rather than the control panel provided.The control panel provided is a very simple button matrix, with no components other than 6 tactile switches on a small PCB. There are 8 wires coming out of the control panel that form a Cat-5 cable and the cable plugs into the controller via an RJ-45 plug & jack.In the short term, I need to be able to "push" any of those buttons via software on a PC. What component should I use to emulate the short circuiting of two wires that is controllable by a micro? I don't yet know how much current flows when the short is made, but it is very small, given the gauge of the wires. I don't know, yet, which (if any) of the wires are considered a ground wire, or Vcc, or anything like that. Each button seems to use two different pins on the RJ-45 plug; there's no one wire common to all buttons, and no wire is used by more than two buttons, if I remember right.Any clues on how to implement this? If I put two pins on a micro to ground, will they conduct between each other? I'm guessing not. there's probably an IC for this but I don't know what it would be. I haven't measured the polarity for each button yet, either; I imagine 6 transistors could do it if I knew the polarities.thanks. see? stupid question.In the long term, the height of the desk will change to suit whomever is logged onto the PC at the time, and whether or not that person is standing or sitting. (computers at a given desk will know if they are accompanied by a chair or not.)

author: sarm
author_rank: Contributor
timestamp: April 12, 2014, 02:09:43 am
content: If it was me, without knowing anything more about the control panel, i could wired up two IC's 4066 quad bilateral switch.

author: nemo000111
author_rank: Contributor
timestamp: April 12, 2014, 02:11:17 am
content: Since you're talking about hooking this up to a computer, I'd use transistor driven relays so everything is isolated.

author: 128er
author_rank: Regular Contributor
timestamp: April 12, 2014, 02:27:12 am
content: Quote from: sarm on April 12, 2014, 02:09:43 amWith the 4066 and a micro, I've controlled a switchmatrix from a cellphone to send messages. Works good. Like sarm says. With the 4066 you dont necessarily have to reverse engineere the remote control.I must ask...Is it so difficult to use the remote control. Or is it just for kicks?

author: Rigby
author_rank: Super Contributor
timestamp: April 12, 2014, 02:32:35 am
content: It's for workstations that are not assigned to a particular person. Someone walks up, logs in, and the desk adjusts its height to suit them. Or, if they've never sat/stood at one before, they can adjust the height to their liking, then it will be saved. If/when they log onto a similar desk elsewhere, it will adjust to the configured height.It's just a proof of concept, for demonstration purposes. It's not likely to go anywhere, but it's something we can show along with the rest of our demos.

author: pickle9000
author_rank: Super Contributor
timestamp: April 12, 2014, 02:37:23 am
content: 4066 is ideal

author: Rigby
author_rank: Super Contributor
timestamp: April 12, 2014, 02:48:18 am
content: Quote from: pickle9000 on April 12, 2014, 02:37:23 amIt's looking that way.If anyone has any experience working with Linak actuators or controllers, I'd like to hear from you.

author: pickle9000
author_rank: Super Contributor
timestamp: April 12, 2014, 03:11:30 am
content: Actuators vary widely, acme to ball screw, position sensing could be limit switches and timing, multi-turn pot or encoder.

author: Rigby
author_rank: Super Contributor
timestamp: April 12, 2014, 03:12:50 am
content: Quote from: pickle9000 on April 12, 2014, 03:11:30 amIt's a data stream from the position encoder, carried over a LIN network to the micro.I know because the stock control panel supports presets, and pushing a preset button will carry the surface to its predefined height, in whichever direction it needs to go to get there. So there's some precise position feedback going on.I'm confident that it's LIN because there is a LIN controller on the board. Maybe two.The PCB supports up to 4 actuators, though the model I have is only populated for 2 actuators.

author: pickle9000
author_rank: Super Contributor
timestamp: April 12, 2014, 04:22:36 am
content: Are you thinking that you may want to send some data directly to the position controller or the device that stores the settings?If it's for a demo I'd probably wimp out and just rig the remote to save time.

author: Rigby
author_rank: Super Contributor
timestamp: April 12, 2014, 01:48:09 pm
content: Quote from: pickle9000 on April 12, 2014, 04:22:36 amEventually, but not yet. I'll likely need to design a new controller, as the existing one has no way to get data into the micro, that I can see.Quote from: pickle9000 on April 12, 2014, 04:22:36 amthat's the plan.

author: David Hess
author_rank: Super Contributor
timestamp: April 13, 2014, 05:37:18 pm
content: I have done this sort of thing before using optocouplers. It may be very important to maintain galvanic isolation.

author: Rigby
author_rank: Super Contributor
timestamp: April 21, 2014, 03:54:15 pm
content: Quote from: David Hess on April 13, 2014, 05:37:18 pmThis could work. There's no common ground, so there's no easy "this pin is negative" deduction that I can do. My understanding is that optocouplers, when active, still act as diodes. Is that the case?given that the 4066 switches are closed when the chip has no power, optocouplers may be the better solution.

author: David Hess
author_rank: Super Contributor
timestamp: April 21, 2014, 05:47:59 pm
content: Quote from: Rigby on April 21, 2014, 03:54:15 pmCommon optocouplers use bipolar transistor outputs so they have a collector to emitter saturation voltage which is significantly lower than the voltage drop of a diode. 10s of millivolts is typical although even the forward voltage drop of a diode would probably not be a problem.Usually the switch matrix is only driven with one polarity so as long as the optocoupler output transistor is oriented correctly, its low reverse blocking voltage is not a problem. If it *is* a problem, then there are optocouplers that use an FET instead of a bipolar transistor which can block or conduct in either direction.

author: Rigby
author_rank: Super Contributor
timestamp: April 23, 2014, 06:51:17 pm
content: Sanity check please.The arduino is known-good. I verified that it's doing what I want with an oscilloscope.The three wires leaving out the bottom go the the desk control box. Shorting the left two of those three will lower the desk. Shorting the right two of those three will raise the desk. the 4066 is meant to act as the switch that shorts those things together.Is there anything clearly stupid that I'm doing with this? The behavior is not at all what I'm after.What should happen: power on the arduino, and after about 3 seconds, the desk should raise for a second, then lower for a second, ad infinitum.what actually happens: immediately on power up, the desk raises all the way and stays there. no oscillation @ 1Hz like expected.

author: Richard Head
author_rank: Frequent Contributor
timestamp: April 24, 2014, 10:12:54 am
content: All of this bullshit just to adjust the desk height? Call me old fashioned but I'd just adjust the chair height. To hell with unneccesary electronics.

author: Rigby
author_rank: Super Contributor
timestamp: April 24, 2014, 11:37:04 am
content: Quote from: Richard Head on April 24, 2014, 10:12:54 amYeah, because all those 555 circuits people start off with are so necessary....What if you have a back problem? A standing desk can fix a lot of issues for you. What if you're a little person? A very low desk can fix an important issue for you. What if the desk in question is in a common area, where any one of a thousand people could be on any given day?This desk, and the ones like it, are the very opposite of unnecessary.