In particular I would like to retrieve:
1. RSSI (received signal strength indicator)
2. RSCP (signal level),
3. SC (Scrambling Code) and
4. EcNo (Signal To Noise Ratio)
Which API function from iPhone SDK can help me to retrieve these values.
Further to your comment above, there is also a GetSignalStrength function referenced among the private functions here.
But if you use one of these GetSignalStrength functions how do you know what you are really getting?
I can't find any documentation, but I would question the assumption that it will always be RSSI.
There is no standard for calculating the number of bars that are shown on a screen. However, there is a standard for calculating the network strength, when the mobile phone decides whether or not to move over to another cell.
For GSM, this standard is RSSI.
For UMTS, it is CPICH RSCP.
For LTE, it is RSRP.
Therefore, if you have 1 single function, that purports to return RSSI in all cases, I ask myself whether it will actually return RSCP when on a UMTS network, and RSRP when on an LTE network. In other words, is it a fudge that over-simplifies the true case?
The 3GPP AT command AT+CESQ (defined here) retrieves network strength. It has parameters that allow for any of the three network types, and you would expect that if you are currently registered on a UMTS cell (for example), that it would return UMTS parameters only. But I can't see any evidence of an equivalent way to get all the data across iPhone APIs.
The next obvious question to ask would be "Can I use that AT command on the iPhone?" Someone has asked that on StackOverflow here. I don't know if AT+CESQ is supported on the iPhone.
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 1 year ago.
Improve this question
I am quite stuck on a board, or something that could fit my needs.
I made a dual Projector 3D System at home, like this : http://www.cinema3dglass.com/Dual_projector_3D_polarization_system.php
And the HDMI can have different (8) formats(Left Right, Above Below, ect..) all here: https://www.tridef.com/user-guide/3d-file-formats
So the needed images on the incoming HDMI port can ble placed like above, and I need to split them on two separate HDMI outputs according to the format, so I can plug them into the projectors.
Basically I need a device that is in the first image in the first link above title: "HDMI Distribution Amplifier & EDID Emulator"
I know an Arduino can't handle this amount of processing, because I overloaded it with simlier tasks.
Can anyone Help me where to start? I foud Panda development board but that's too expensive.
Or if there is a not owerly expensive device existing for this task, I could buy that.
I manadged to use the system from Tridef 3D but that's hard to get working.
I'd like my device to get the input from a Chromecast 2.0, but if it's not possible a normal player 'll do it.
I found some devices called HDMI Demultiplexer they simply cut one half of the input, but that's quite expensieve, for 260$ and two would be needed.
Help me please.
Thanks in advance.
From the HDMI specification at page 56 the transfer/interconnection looks like this:
I would start with interleaved left/right format where even pixels are left and odd pixels are right because there is high chance that it does not need any FIFO. If you want standard left/right then you need single line FIFO for each channel and for up/down full image FIFO. In case variable clock is supported by your HW then this simplified example should work:
You need to add H/V sync decoder from Channel0 to reset the binary counter. Binary counter counts which data address is being processed. The single data-line to the AND gates should be D1 half of the input clock but not entirely you need to toggle between D0 and D1 depends in the timing of data processed (for pixels it would be D1 and for other data it would be D0) that is the variable clock I mentioned before. The comparator just compares the address against predefined constants (like half of line for non interleaved left/right format or detect even odd for interleaved format but both must take +/- other data offsets) beware the transfer is on bits not Bytes so the address will be multiplied by number of bits per data chunk ... The gates just toggle clock between left and right part. LATCHES make sure output signal will be not mixed and also boost the signal.
I would start with oscilloscope measurements of the channels so you can see how the data is transfered and then experiment-ate. If you use FPGA then you do not need to make any changes to the board while ecxperimentating with configurations as the circuit will be solely inside FPGA.
If variable clock is not supported then you need to use FIFO and or RAM to store the full line/image and then send the appropriate parts to their connectors. For that you most likely need full decoding capability so use the SIL9134 + SIL9135. Halving resolution will introduce timing problems because you will need more time to send half speed half frame then the full speed full frame (the auxiliary and sync data is copied not halved). If the sending has big enough gaps you could fit the missing time there but again not all HW can support it losing sync/flickering/etc. In such case you could change the resolution to a bit smaller (after halving) to fit in the send time ... or enlarge thi full resolution input (in x axis).
Good luck with your quest.
I have designed a GUI to calibrate my sound card using MATLAB, I am able to record my input signal. I would like to calibrate my input.
How do I do that?
My GUI should be capable to adapt to different sound cards and get the dBV values, hence the Calibration is required. Any help would be appreciated.
A: This is a task from a Metrology, rather than from a programming area
To get the job done, you need a fully-controlled-environment to re-run a defined-input/known-output experiment.
In principle,
your both all your devices and your setup, has to be controlled - i.e.
your MIC-Input-accoustic/electric converter, while [dBa] -> [V] conversion is
"readable" down the cable path, it is not a principally important value per-se,
your CABLE-wire-path, which shall not be either neglected or forgotten,
your SND-Card-A/D converter,
your AUDIO-pre-Calibration Sound-Sample,
your TEST-pre-Calibration Environment
so as to be able to pre-Calibrate your devices for measurments.
The calibration itself can be achieved right by using the same AUDIO Sound-Sample in the same TEST Environment and be that measured / calibrated / by another device, that was certified at a locally recognised reference Authority to have a certain level of precision ( a guarantee that it's readings will not be outside a natl./intl. recognised precision class' envelope from correct/exact values ).
Note: you may want to pre-Calibrate your MIC+SND-A/D setup inside your in-vitro controlled environment specifically across a wide range of frequencies, so as to avoid frequency-dependent variation of the measurement-conversion path. Thus your pre-Calibration would have sort of Calibration-curve as an input for your further tests to be performed in-vivo
I would like to know if there are some libraries/algorithms/techniques that help to extract the user context (walking/standing) from accelerometer data (extracted from any smartphone)?
For example, I would collect accelerometer data every 5 seconds for a definite period of time and then identify the user context (ex. for the first 5 minutes, the user was walking, then the user was standing for a minute, and then he continued walking for another 3 minutes).
Thank you very much in advance :)
Check new activity recognization apis
http://developer.android.com/google/play-services/location.html
its still a research topic,please look at this paper which discuss the algorithm
http://www.enggjournals.com/ijcse/doc/IJCSE12-04-05-266.pdf
I don't know of any such library.
It is a very time consuming task to write such a library. Basically, you would build a database of "user context" that you wish to recognize.
Then you collect data and compare it to those in the database. As for how to compare, see Store orientation to an array - and compare, the same holds for accelerometer.
Walking/running data is analogous to heart-rate data in a lot of ways. In terms of getting the noise filtered and getting smooth peaks, look into noise filtering and peak detection algorithms. The following is used to obtain heart-rate information for heart patients, it should be a good starting point : http://www.docstoc.com/docs/22491202/Pan-Tompkins-algorithm-algorithm-to-detect-QRS-complex-in-ECG
Think about how you want to filter out the noise and detect peaks; the filters will obviously depend on the raw data you gather, but it's good to have a general idea of what kind of filtering you'd want to do on your data. Think about what needs to be done once you have filtered data. In your case, think about how you would go about designing an algorithm to find out when the data indicates activity (like walking, running,etc.), and when it shows the user being stationary. This is a fairly challenging problem to solve, once you consider the dynamics of the device itself (how it's positioned when the user is walking/running), and the fact that there are very few (if not no) benchmarked algos that do this with raw smartphone data.
Start with determining the appropriate algorithms, and then tackle the complexities (mentioned above) one by one.
I want to compare 2 audio files programmatically.
For example: I have a sound file in my iPhone app, and then I record another one. I want to check if the existing sound matches the recorded sound or not ( - similar to voice recognition).
How can I accomplish this?
Have a server doing audio fingerprinting computation that is not suitable for mobile device anyway. And then your mobile app uploads your files to the server and gets the analysis result for display. So I don't think programming language implementing it matters much. Following are a few AF implementations.
Java: http://www.redcode.nl/blog/2010/06/creating-shazam-in-java/
VC++: http://code.google.com/p/musicip-libofa/
C#: https://web.archive.org/web/20190128062416/https://www.codeproject.com/Articles/206507/Duplicates-detector-via-audio-fingerprinting
I know the question has been asked a long time ago, but a clear answer could help someone else.
The libraries from Echoprint ( website: echoprint.me/start ) will help you solve the following problems :
De-duplicate a big collection
Identify (Track, Artist ...) a song on a hard drive or on a server
Run an Echoprint server with your data
Identify a song on an iOS device
PS: For more music-oriented features, you can check the list of APIs here.
If you want to implement Fingerprinting by yourself, you should read the docs listed as references here, and probably have a look at musicip-libofa on Google Code
Hope this will help ;)
Apply bandpass filter to reduce noise
Normalize for amplitude
Calculate the cross-correlation
It can be fairly Mhz intensive.
The DSP details are in the well known text:
Digital Signal Processing by
Alan V. Oppenheim and Ronald W. Schafer
I think as well you may try to select a few second sample from both audio track, mnormalise them in amplitude and reduce noise with a band pass filter and after try to use a correlator.
for instance you may take a 5 second sample of one of the thwo and made it slide over the second one computing a cross corelation for any time you shift. (be carefull that if you take a too small pachet you may have high correlation when not expeced and you will soffer the side effect due to the croping of the signal and the crosscorrelation).
After yo can collect an array with al the results of the cross correlation and get the index of the maximun.
You should then set experimentally up threshould o decide when yo assume the pachet to b the same. this will change depending on the quality of the audio track you are comparing.
I implemented a correator to receive and distinguish preamble in wireless communication. My script is actually done in matlab. if you are interested i can try to find the common part and send it to you.
It would be a too long code to be pasted hene in the forum. if you want just let me know and i will send it to ya asap.
cheers
Yamaha InfoSound and ShopKick application use technologies that allow to transfer data using ultrasound. That is playing an inaudible signal (>18kHz) that can be picked up by modern mobile phones (iOS, Android).
What is the approach used in such technologies? What kind of modulation they use?
I see several problems with this approach. First, 18kHz is not inaudible. Many people cannot hear it, especially as they age, but I know I certainly can (I do regular hearing tests, work-related). Also, most phones have different low-pass filters on their A/D converters, and many devices, especially older Android ones (I've personally seen that happen), filter everything below 16 kHz or so. Your app therefore is not guaranteed to work on any hardware. The iPhone should probably be able to do it.
In terms of modulation, it could be anything really, but I would definitely rule out AM. Sound has next to zero robustness when it comes to volume. If I were to implement something like that, I would go with FSK. I would think that PSK would fail due to acoustic reflections and such. The difficulty is that you're working with non-robust energy transfer within a very narrow bandwidth. I certainly do not doubt that it can be achieved, but I don't see something like this proving reliable. Just IMHO, that is.
Update: Now that i think about it, a plain on-off would work with a single tone if you're not transferring any data, just some short signals.
Can't say for Yamaha InfoSound and ShopKick, but what we used in our project was a variation of frequency modulation: the frequency of the carrier is modulated by a digital binary signal, where 0 and 1 correspond to 17 kHz and 18 kHz respectively. As for demodulator, we tried heterodyne. More details you could find here: http://rnd.azoft.com/mobile-app-transering-data-using-ultrasound/
There's nothing special in being ultrasound, the principle is the same as data transmission through a modem, so any digital modulation is -in principle- feasible. You only have a specific frequency band (above 18khz) and some practical requisites (the medium is very unreliable, I guess) that suggest to use a simple-robust scheme with low-bit rate.
I don't know how they do it but this is how I do it:
If it is a string then make sure it's not a long one (the longer the higher is the error probability ). Lets assume we're working with the vital part of the ASCII code, namely up to character number 127, then all you need is 7 bits per character. Transform this character into bits and modulate those bits using QFSK (there are several modulations to choose from, frequency shift based ones have turned out to be the most robust I've tried from the conventional ones... I've created my own modulation scheme for this use case). Select the carrier frequencies as 18.5,19,19.5, and 20 kHz (if you want to be mathematically strict in your design, select frequency values that assure you both orthogonality and phase continuity at symbol transitions, if you can't, a good workaround to avoid abrupt symbols transitions is to multiply your symbols by a window of the same size, eg. a Gaussian or Bartlet ). In my experience you can move this values in the range from 17.5 to 20.5 kHz (if you go lower it will start to bother people using your app, if you go higher the average type microphone frequency response will attenuate your transmission and induce unwanted errors).
On the receiver side implement a correlation or matched filter receiver (an FFT receiver works as well, specially a zero padded one but it might be a little bit slower, I wouldn't recommend Goertzel because frequency shift due to Doppler effect or speaker-microphone non-linearities could affect your reception). Once you have received the bit stream make characters with them and you will recover your message
If you face too many broadcasting errors, try selecting a higher amount of samples per symbol or band-pass filtering each frequency value before giving them to the demodulator, using an error correction code such as BCH or Reed Solomon is sometimes the only way to assure an error free communication.
One topic everybody always forgets to talk about is synchronization (to know on the receiver side when the transmission has begun), you have to be creative here and make a lot a tests with a lot of phones before you can derive an actual detection threshold that works on all, notice that this might also be distance dependent
If you are unfamiliar with these subjects I would recommend a couple of great books:
Digital Modulation Techniques from Fuqin Xiong
DIGITAL COMMUNICATIONS Fundamentals and Applications from BERNARD SKLAR
Digital Communications from John G. Proakis
You might have luck with a library I created for sound-based modems, libquiet. It gives you a handful of profiles to work from, including a slow "Ultrasonic whisper" profile with spectral content above 19kHz. The library is written in C but would require some work to interface with iOS.