#257808 - 07/06/2005 01:43
The In-Car Wireless empeg Sync Challenge
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
In the past, there have been a myriad of threads where people have hypothesized, postulated, and speculated on strategies for having your empeg in your car, parked at your home, and being able to connect to it and sync files to it. This task in and of itself is not difficult, as people have fashioned little metal brackets to allow car-docked ethernet connectivity, ran the ethernet to a bridged access point, and achieved the desired result.
However, I haven't heard from anyone who's gone a step further and elegantly integrated this setup into their car, particularly in terms of providing power in such a way that the wifi AP doesn't empty the battery overnight (or over the course of a few days, as the case may be.)
To put it more succinctly, I'm looking for strategies for how one might wire their empeg and in-car wifi connection such that, when the key is removed, the empeg and wifi stay powered on for a period of time, while they try to detect tha they're at home. After 5 minutes (or whatever,) if they can't get through to the mothership, they power down.
The idea being, when my car pulls into the driveway, it contacts my server, and if it gets through, it initiates an mp3tofid/rsync operation to pull down new music. I would consider this the Holy Grail of painless empeg synchronization.
Extra bonus points for any solution that would allow the mothership to "wake up" the empeg and access point, but with no true "wake on LAN" capabilities, that's probably a steeper hill to climb.
So, any ideas?
|
Top
|
|
|
|
#257809 - 07/06/2005 04:24
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
pooh-bah
Registered: 12/02/2002
Posts: 2298
Loc: Berkeley, California
|
Hmmm...
The empeg serial port provides power when the empeg is on - wire this to a relay which powers the wireless bridge, then the bridge is powered up whenever the empeg is on. Is this line high when the empeg is sleeping? Hopefully, but probably not. If it isn't, you need a way to prevent the empeg from sleeping when you turn the car off until it's sure you're not at home.
Perhaps a simpler solution would to have the empeg attempt to sync at 3AM every morning. Then you could simply get a timer which powered up the empeg and the bridge, and let it do it's thing. The only problem that arises is that if your sync takes longer than the timer allows, it'll get cut off. Will this leave a semi-working player in good enough shape to wait till it gets enough time the next night?
Those are some thoughts. I look forward to seeing how you actually do this, as it'd be a nice feature and I finally moved into a place with my own garage.
Matthew
|
Top
|
|
|
|
#257810 - 07/06/2005 07:15
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
veteran
Registered: 01/10/2001
Posts: 1307
Loc: Amsterdam, The Netherlands
|
I did try out a wireless bridge, but had trouble placing it so that it would get decent reception. I just wired everything to a relay powered by the key - and went back and turned it off after everything was done. Part of my motivation was the secondary application of activating garege door opener when within range.
|
Top
|
|
|
|
#257811 - 07/06/2005 10:19
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
carpal tunnel
Registered: 29/08/2000
Posts: 14496
Loc: Canada
|
crazymelki has done this.
|
Top
|
|
|
|
#257812 - 07/06/2005 11:12
Re: The In-Car Wireless empeg Sync Challenge
[Re: mlord]
|
carpal tunnel
Registered: 30/10/2000
Posts: 4931
Loc: New Jersey, USA
|
Quote: crazymelki has done this.
I think he's on vacation until the 19th. He also mentioned that email sent to him may not get saved by his mail server until he's able to check it when he gets back.
_________________________
-Rob Riccardelli 80GB 16MB MK2 090000736
|
Top
|
|
|
|
#257813 - 07/06/2005 12:44
Re: The In-Car Wireless empeg Sync Challenge
[Re: julf]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Quote: I did try out a wireless bridge, but had trouble placing it so that it would get decent reception.
Hmm. This could indeed be a problem. If need be, I can have one of my in-home APs located in the garage, so the signal would only need to travel a couple feet. The in-car bridge would probably still not work well in the trunk, but might work if I put it on the rear deck behind the back seats. I will obviously test this out before doing any kind of permanent wiring in the car.
Quote: I just wired everything to a relay powered by the key - and went back and turned it off after everything was done.
Yeah, that's really what I'm trying to avoid if at all possible.
|
Top
|
|
|
|
#257814 - 07/06/2005 12:46
Re: The In-Car Wireless empeg Sync Challenge
[Re: matthew_k]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Quote: Perhaps a simpler solution would to have the empeg attempt to sync at 3AM every morning. Then you could simply get a timer which powered up the empeg and the bridge, and let it do it's thing. The only problem that arises is that if your sync takes longer than the timer allows, it'll get cut off. Will this leave a semi-working player in good enough shape to wait till it gets enough time the next night?
Interrupted syncs are not a problem with mp3tofid/rsync. The timer solution, though not ideal, does sound reasonable as a backup plan. Just need to find a timer that's easy to integrate into a car.
|
Top
|
|
|
|
#257815 - 07/06/2005 12:47
Re: The In-Car Wireless empeg Sync Challenge
[Re: mlord]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Quote: crazymelki has done this.
Cool, I eagerly await his return to hear about how he's done it!
|
Top
|
|
|
|
#257816 - 07/06/2005 13:39
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
I haven't actually done any of this myself, but it seems to me that you ought to be able to wire something up where you have a relay that turns the power to the AP on and off signalled by the accessory line to the empeg so that when the ACC line goes off, the AP comes on. But then have another attached to the permanent line so that when the empeg stops drawing power, it powers the AP off. Then just set the power-off time on the empeg to be reasonably long. This way, the AP will usually be off, you turn off your car and it powers up until the empeg powers completely down, at which point it'll go back down. Now, I'm not sure if there's a userland program to power down the empeg when you're done syncing, but it seems like it ought to be possible to write one if there's not.
_________________________
Bitt Faulk
|
Top
|
|
|
|
#257817 - 07/06/2005 13:44
Re: The In-Car Wireless empeg Sync Challenge
[Re: wfaulk]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Quote: Now, I'm not sure if there's a userland program to power down the empeg when you're done syncing, but it seems like it ought to be possible to write one if there's not.
I don't know anything about the mechanism the player software (or is it the kernel?) uses to fully power down the empeg after the standby timer expires. If that were exposed as a kernel call, powering down the empeg after the sync would be easily solved.
|
Top
|
|
|
|
#257818 - 07/06/2005 13:55
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
Now that I think about it, isn't there a power-down-after-sync checkbox somewhere in Emplode?
_________________________
Bitt Faulk
|
Top
|
|
|
|
#257819 - 07/06/2005 19:21
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
carpal tunnel
Registered: 18/01/2000
Posts: 5683
Loc: London, UK
|
Quote: If that were exposed as a kernel call, powering down the empeg after the sync would be easily solved.
It'll be an ioctl or something on something in /dev.
_________________________
-- roger
|
Top
|
|
|
|
#257820 - 07/06/2005 19:22
Re: The In-Car Wireless empeg Sync Challenge
[Re: wfaulk]
|
carpal tunnel
Registered: 18/01/2000
Posts: 5683
Loc: London, UK
|
Quote: a power-down-after-sync checkbox somewhere in Emplode?
There certainly used to be, in emplode 1.0. I don't recall whether I copied that feature across to 2.0 when I re-wrote it.
_________________________
-- roger
|
Top
|
|
|
|
#257821 - 07/06/2005 19:32
Re: The In-Car Wireless empeg Sync Challenge
[Re: Roger]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Okay, I found the aptly-named EMPEG_POWER_TURNOFF ioctl in empeg_power.c, so telling the empeg to power down should be no problem. I'll just have to disable/ignore the player's own power-down timeout and enforce my own.
Now I just gotta work out the hardware bits.
|
Top
|
|
|
|
#257822 - 07/06/2005 20:11
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
pooh-bah
Registered: 12/02/2002
Posts: 2298
Loc: Berkeley, California
|
If you prevent the power down, shouldn't all you need to do is run the bridge off of a relay powered by the serial port power? Then player "power-down" triggers the sync and real power down. You just need to verify that the wireless bridge autosearches for your wifi network and auto associates soon after it comes into range.
Matthew
|
Top
|
|
|
|
#257823 - 07/06/2005 20:32
Re: The In-Car Wireless empeg Sync Challenge
[Re: matthew_k]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Quote: If you prevent the power down, shouldn't all you need to do is run the bridge off of a relay powered by the serial port power? Then player "power-down" triggers the sync and real power down.
I guess that might work, it sounds logical, anyway.
Quote: You just need to verify that the wireless bridge autosearches for your wifi network and auto associates soon after it comes into range.
Yup, I know it works that way on Linksys WRT54GS units, which is what I'm looking to use. Typically takes 10 seconds or so from bootup until the time a client can reach my network.
|
Top
|
|
|
|
#257824 - 07/06/2005 20:39
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
addict
Registered: 29/06/2002
Posts: 531
Loc: Triangle, VA
|
Youd have to make sure to power it down every time you left it in the car that way though. otherwise the empeg and ap would always be on.
_________________________
-D
Modifying and Tweaking is a journey,
not a destination................................
MKIIa : 60gig - 040103286 - Blue - v2 + PCATS tuner
MKIIa : 20gig - 040103260 - Blue - v3a8 + Mark Lord Special Edition Cherry Dock
|
Top
|
|
|
|
#257825 - 07/06/2005 20:58
Re: The In-Car Wireless empeg Sync Challenge
[Re: SonicSnoop]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Quote: Youd have to make sure to power it down every time you left it in the car that way though. otherwise the empeg and ap would always be on.
Yeah, the idea is I'd write a piece of software that tries to access my home network for 5 minutes or so after the accessory line goes low (key is removed.) If it can't phone home, it powers down the empeg, and that in turn powers down the AP. How that all gets wired is a little past my grasp at the moment, but I think the software pieces are all there, or I can write them.
|
Top
|
|
|
|
#257826 - 08/06/2005 17:07
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
So, uh, would the resulting system look something like this?
Diagram
The router I'd be using has a 12V 1000 mA power supply. I'm told the DC/DC converter bit may not be necessary, but would be there to take care of any power spikes that come from the car's power.
So does that look like it'd work?
Attachments
257451-empeg-wireless.png (227 downloads)
|
Top
|
|
|
|
#257827 - 08/06/2005 18:10
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
pooh-bah
Registered: 12/02/2002
Posts: 2298
Loc: Berkeley, California
|
That looks about right to me. You've left off the ground for the relay/dc-dc/ap segment. I assume the relay and dc-dc converter should be chassis grounded, and the AP hooked up to the dc-dc converters positive and negative terminals, but that's all a complete guess.
Matthew
|
Top
|
|
|
|
#257828 - 13/06/2005 19:35
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
addict
Registered: 14/11/2000
Posts: 474
Loc: The Hague, the Netherlands
|
There's the M1-ATX power supply that does exactly what you want. It features a timer controlled power down function, and it automatically powers down if your battery starts to drop power. And Opus also make similar external power supplies. Pim
|
Top
|
|
|
|
#257829 - 03/07/2005 19:46
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Okay, due to extreme suckitude, I believe my strategy is completely wrong. For starters, the power line that's on the serial port is 12V, not 5V. That would normally work to my advantage (wireless bridge's power supply is 12V) but unfortunately, according to this thread, this power signal goes away when the empeg is in standby. Because it goes into standby when I turn the ignition off, this means no power to the bridge. I wish I had seen that thread earlier, or I could have saved myself a lot of time thinking about this. The solutions mentioned later in that thread are way beyond my comprehension, so it looks like I'll have to use some kind of timer like the two that pim mentions.
Well, so much for that.
|
Top
|
|
|
|
#257830 - 03/07/2005 21:55
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
pooh-bah
Registered: 12/02/2002
Posts: 2298
Loc: Berkeley, California
|
Quote: Is this line high when the empeg is sleeping? Hopefully, but probably not. If it isn't, you need a way to prevent the empeg from sleeping when you turn the car off until it's sure you're not at home.
Any chance of delaying the sleeping? Hijack could get the sleep command, look and see if you're home, and shut off or sync depending on what it finds?
Does your amp thump when you start the car with the empeg playing? That'd be the only real downside to delaying the sleeping for me...
Matthew
|
Top
|
|
|
|
#257831 - 03/07/2005 22:24
Re: The In-Car Wireless empeg Sync Challenge
[Re: matthew_k]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Quote: Any chance of delaying the sleeping? Hijack could get the sleep command, look and see if you're home, and shut off or sync depending on what it finds?
Sure, that could work, but I was hoping for something that would have kept it in standby mode. I guess that's not really feasible without some serious jiggery pokery.
Quote: Does your amp thump when you start the car with the empeg playing? That'd be the only real downside to delaying the sleeping for me...
I'm not sure, because it's not installed in the new car yet. I will find out on Tuesday when they install it. I didn't have any amp thump in my last car but that was with a separate head unit (bypassing the factory amp) where in my new car I'll be going from the empeg right into the factory amp.
|
Top
|
|
|
|
#257832 - 06/07/2005 02:07
Re: The In-Car Wireless empeg Sync Challenge
[Re: tonyc]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Stop the press!
Forget all this hardware business. Reading old posts has made me realize something that should have been driven into my skull already: the empeg can allegedly wake itself up from power-off state to standby! The way I understand it (and I can't test this because my empeg isn't installed in my new vehicle yet) all that needs to be done is to call the EMPEG_POWER_WAKETIME ioctl to tell it to wake up after a certain time. Assuming this works, I could tell it to wake every 4 hours (or whatever.) Once it goes from power off to standby, I can probably break it out of standby by injecting button codes, or some minor kernel hack. At that point, the empeg's amp power line has juice, and that can go to my wireless bridge. Or, that's my hypothesis anyway...
Now, since my install isn't until Saturday, and I can't test this, I'd appreciate it if a brave (and rather bored) soul could put the attached binary on their empeg, put it in a Hijack MENUEXEC entry, and run it while it's in their car. (For me, on AC power in a mlord dock, it powers down the drives briefly, but doesn't turn the empeg off.)
What should happen when you run it is your empeg should (hopefully) power down and then magically power on (into standby mode, I guess) after 15 seconds or so. If it doesn't power down your empeg, then turn your ignition off, and see if the empeg comes on within 15 seconds.
Any takers?
Attachments
259490-powertest (217 downloads)
|
Top
|
|
|
|
|
|