Comments (12)
I think the problem is that rtl_fm doesn't support upsampling, only downsampling. There might be a way to achieve that with sox, but your best option is probably to modify this line to use 8000
instead of 48000
, and then you can use -s 8k
in your rtl_fm command without resampling. If you give that a try let me know if it works, I imagine it should
from timestampsdr.
I propose to add this parameter (sampleRate) to config.js.
from timestampsdr.
Yeah that sounds like a good idea, I'll add it in when I get a chance
from timestampsdr.
Added sampleRate parameter in 03134ca
from timestampsdr.
Ah, I hadn't thought about this. timestampSDR uses node-wav for creating wav files, and regardless of what input rate you provide, I guess it writes at 44100. I'll look into this more this weekend
from timestampsdr.
It works! Thank you !
from timestampsdr.
Hi,
@qualitymanifest I've checked your new code and I feel that something wrong :)
I've changed sampleRate
in config.js
to 8000
but program saved file with 44100
Can you check please?
from timestampsdr.
from timestampsdr.
@kovalroma I was way off, node-wav
is definitely not hardcoded to use 44100, it uses the sample rate you provide and I was providing it an undefined
sample rate. Whoops! Sorry about that. Anyway I just pushed up a few commits that should fix that, and also added the option to specify channels
and bitDepth
from timestampsdr.
@qualitymanifest hey, still have an issue with default settings.
pi@raspberrypi:~/timestampSDR $ node main.js
/home/pi/timestampSDR/src/handle_options.js:54
if (key === "sampleRate" && isNumInvalid({ num: val, min: 1, max: 4_300_000_000, isInt: true, })) {
^
SyntaxError: Invalid or unexpected token
at createScript (vm.js:80:10)
at Object.runInThisContext (vm.js:139:10)
at Module._compile (module.js:616:28)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (/home/pi/timestampSDR/main.js:3:23)
from timestampsdr.
I think this is incorrect
https://github.com/qualitymanifest/timestampSDR/blob/master/src/handle_options.js#L54
Should be
if (key === "sampleRate" && isNumInvalid({ num: val, min: 1, max: 4300000000, isInt: true, })) {
return wasInvalid(option, key, "Must be an integer between 1 and 4300000000");
?
from timestampsdr.
That is using numeric separators, which were apparently introduced in Node 12.5.0 - I thought they had been around for longer than that, this was my first time using them. Since they're just for developer convenience, there's no sense in breaking support for older versions of Node just for that, so I just pushed a commit removing them. Should be good now, let me know if you have any other issues
from timestampsdr.
Related Issues (7)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from timestampsdr.