Rockbox Technical Forums

Support and General Use => Recording => Topic started by: fredoo on March 31, 2013, 10:34:44 AM

Title: Use RockBox sound detection feature, and somehow store files to PC?
Post by: fredoo on March 31, 2013, 10:34:44 AM
Hi
RockBox has a great recording-on-noise feature. I am wondering if it is somehow possible to download the files created by the feature to a PC connected to RockBox, while RockBox is working and recording? I have Sansa Fuze.

I see two general ways to do this. One way is to have RockBox aware of the whole process. The other way is to just give to the PC access to filesystem of Sansa Fuze while it is in normal operation. Some script would then examine recorded files, detect the ones that are finished recording, and download & delete them.

Is this possible?

Best,
Fred
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: saratoga on March 31, 2013, 01:26:59 PM
In msc mode only one device can mount storage so there is no way to do this with our current USB system.
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: fredoo on March 31, 2013, 09:32:09 PM
In msc mode only one device can mount storage so there is no way to do this with our current USB system.

Maybe Rockbox can forward signal from microphone to headphone out, but only when the Trigger mechanism signals to do so?

This way the PC could harvest signal from line-in.. I am aware that this probably requires coding, but who knows maybe I can help. I am surprised by effectiveness of the Triggered recording. My old Fuze can work for 12 hours catching very subtle sounds precisely. Doing the same with PC is IMO extremely hard (sox, pipes, and other stuff that just doesn't compare).
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: saratoga on March 31, 2013, 10:35:31 PM
Maybe Rockbox can forward signal from microphone to headphone out, but only when the Trigger mechanism signals to do so?

Just implement triggering on your PC directly.  It will be much easier and involve vastly less programming. 
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: fredoo on April 01, 2013, 06:43:16 AM
Just implement triggering on your PC directly.  It will be much easier and involve vastly less programming.

But the Fuze is so compact, can be hidden in so many places, has long battery life and does it's job so well with RockBox. Argh.. On the other hand, it is also a little old in design: no bluetooth, no WiFi, no <<Internet of Things>> stuff. So it's hard to integrate and to use as a kind of sensor. One could probably buy this kind of sensor explicitly.

Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: gevaerts on April 01, 2013, 09:42:34 AM
Just implement triggering on your PC directly.  It will be much easier and involve vastly less programming.
But the Fuze is so compact, can be hidden in so many places, has long battery life and does it's job so well with RockBox. A

That doesn't make any sense. You explicitly wanted to connect it to a PC, which means the competing device is a *microphone*. Surely those are not any less compact?
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: fredoo on April 01, 2013, 10:39:39 PM
But the Fuze is so compact, can be hidden in so many places, has long battery life and does it's job so well with RockBox. A

That doesn't make any sense. You explicitely wanted to connect it to a PC, which means the competing device is a *microphone*. Surely those are not any less compact?

Yes, this solution would mean giving up the compactness. So one step backwards. But then it would be possible to search for a solution. Maybe some USB-over-radio plug :] Or USB-over-powerline.
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: [Saint] on April 03, 2013, 02:33:27 AM
Yes, this solution would mean giving up the compactness.

I think you may have parsed gevaerts' statement incorrectly.

If not, the response confuses me. There are many USB microphones around that make the Fuze look massive in comparison. I happen to have several myself.


[Saint]
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: fredoo on April 03, 2013, 05:56:16 AM
Yes, this solution would mean giving up the compactness.

I think you may have parsed gevaerts' statement incorrectly.

If not, the response confuses me. There are many USB microphones around that make the Fuze look massive in comparison. I happen to have several myself.
[Saint]

True I've parsed gevaerts' post incorrectly. Part of my answer still holds: online-connecting to PC via USB is to be a first step, to just find a way of getting files out of Rockbox while it is working.

USB microphone doesn't have sansa's battery, internal storage and the cool triggered recording. The trigger works really well. The battery and internal storage have good capacity. This gives cool use cases. For example, if power outage would occur shutting down PC, the Sansa Fuze and Rockbox could still operate for about 10-12 hours. This is cool from surveillance perspective. Sansa Fuze could be hidden e.g. behind AC connector. If intruder would shut of power, break into house, and stole surveillance PC, you still would have some audio trace stored in Sansa.
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: gevaerts on April 03, 2013, 06:07:29 AM
USB microphone doesn't have sansa's battery and the cool triggered recording. It works really well.

You're still missing the point. You're going to attach the thing with a cable, why do you need a battery? You seem to be deliberately trying to find the most convoluted way to achieve something.
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: fredoo on April 03, 2013, 07:50:48 AM
You're still missing the point. You're going to attach the thing with a cable, why do you need a battery? You seem to be deliberately trying to find the most convoluted way to achieve something.

I've updated my post simultaneously, I think it explains my point of view.
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: evilnick on April 03, 2013, 11:02:04 AM
While it may be *possible* to use a Sansa Fuze as a triggered recording device that you could hide in a wall outlet that could direct the recorded file to another place (that part wouldn't be possible right now at least) and which uses the battery of the Fuze as a quasi-UPS device and reverts to storing the recorded file on its own internal memory/SD card if the external storage suddenly disappears... aren't there other products out there that would be far more easy to use and wouldn't require such hard work?

Also, if you're going to use it as a security feature when you're not at home, how do you then use it to listen to music with whilst out and about?

It seems to me that you may be attempting to do too much with one device.

Having said that, I do wish you all the luck in this endeavour.
Title: Re: Use RockBox sound detection feature, and somehow store files to PC?
Post by: fredoo on April 04, 2013, 01:24:36 AM
... aren't there other products out there that would be far more easy to use and wouldn't require such hard work?

I'm into this recently. I was looking on Arduino or Raspberry Pi hacks. While they provide their own cool capabilities, they are apparently far less compact than a MP4 player. My research was shallow, so I might be to some degree wrong. I was also looking on 6LoWPAN stuff, sensors etc. Connecting various devices becomes an active topic recently. My main motivation is that Fuze + Rockbox provides multiple problems solved out of the box: battery, microphone, trigger mechanism, small size, extensible storage. And each of these components is good in quality (the microphone for example, that's why I've enumerated it explicitly). The price is also important. Fuze is cheaper than Arduino or RPI with additional shield, battery, etc. And it's easy to repeat Fuze+Rockbox setup: it's just buying another device and that's it (Arduino/RPI would mean some assembling). Other devices, not hack-toys but specialized surveillance devices are not cheap.

Also, if you're going to use it as a security feature when you're not at home, how do you then use it to listen to music with whilst out and about?

It seems to me that you may be attempting to do too much with one device.

Having said that, I do wish you all the luck in this endeavour.

I would buy additional device, the surveillance is important to me.

Maybe an simplier way is possible: Is it hard to make triggered recording remove old files, when storage is full, and continue to record fresh sound? This would create something like circular buffer. If something suspicious would happen, Fuze+Rockbox would store recordings from last 4-12 hours or more (depends on frequency of the trigger activation and on storage size).