If you have an expirience in working with ICM-20948, give me answers to the questions.
1) How to read data from WHO_AM_I register.
2) How to get data from magnetometer registers.
I need some examples of working code.
I need only code, not reasoning.
There is several code exemple on github web site. Invensense have also exemples in their developer section.
Related
I'm creating an app which generates a random question from a list (currently stored as a Numbers doc). Once that question is answered by the user, the unique question ID, the question itself and their answer is stored in core data.
When the user requests a new question one will be generated randomly from the original document and it will then be cross referenced with core data to find out if the user has previous answered that question.
I haven't included the code of my app at the moment as I'm not really looking for specific coding help. As someone who is new to the world of code I'm just looking for a nudge in the right direction for me to go and do more studying.
JSON looks like a possible, but the more I read about that the more it seems that it is about an app communicating with a website. I don't really want the questions to be accessed by just anyone, so putting them on my website might not work? Could I do it with a file local in the app? maybe a CSV?
I'm anticipating the file may become quite big as I add more questions - so I'm not sure if that changes things?
Thanks so much in advance, and apologies if this isn't quite the right way to ask questions on here.
I'm just looking for a nudge in the right direction for me to go and
do more studying.
There are many options to solve your problem. Each option depends on your skill, time and if the solution is even necessary for the app you want to make. In the end it's you who decides on which solution solves your problem. There are a few options:
creating your own backend
have a local file in your app
or use a third party service like Firebase.
Each option has its own benefits. Just to list a few:
Local file:
You could have a local file in nearly any format (XML, JSON, .plist) etc. The downside is that your app isn't dynamic - you have to manually keep adding text to this file and update your app trough the App Store for your users to see these changes. If you're going with this approach, I'd recommend using a .plist or a JSON file which is saved in your project. How to implement this correctly is beyond the scope of the question, but there are plenty tutorials out there to help you getting started.
You could put your data in a .plist file. This is nothing more than a dictionary with key-value data (same principle as JSON where each key has a value). An example:
question1 is the key, of type String, containing the value "How are you today". It's easy to read from this .plist since it's the same principle as JSON.
Also, JSON is just a format, it's used often to communicate with websites, but it's not limited to sites only.
Custom backend
This means that you make a backend on which your app can communicate with. You'd have to host your backend, write logic / code on your backend and so on. This can be very time consuming, especially if your app isn't that big/demanding. I wouldn't recommend this unless you have the experience, time, patience and need for this solution.
Third party
This can be a nice solution. Using a third party service like Firebase means that you have your data online. The Firebase library has been well tested and has great documentation to get you started. It's secure, fast, simple but .. it does take a little bit of time to learn how it works - but the end result is that you have a dynamic app where you can add, delete, edit questions and so on. This data can be protected if you wish - which means only authenticated users can access this data (Nobody else will be spying on your data :))
I don't really want the questions to be accessed by just anyone, so
putting them on my website might not work?
Read custom backend and Third Party.
Could I do it with a file local in the app?
Yes. Read Local file.
maybe a CSV?
That's possible but I wouldn't recommend it, but that's a personal opinion. I find it outdated and it's more difficult to work with than JSON.
I'm anticipating the file may become quite big as I add more questions
- so I'm not sure if that changes things?
What is a big file? Nowadays reading a "big" JSON file is probably nothing more than a few MB at most. Your phone reads this in no time. This won't be an issue for your phone or app.
I was wondering if there is an application, and if not if it's worth writing one, that can gather meaningful data from old e-mails. I'm thinking things like:
Instructions (that could become "5 steps to..." posts)
Definitions
etc
Any idea? Suggestions? etc?
Well, I can offer the same solution as I did to this post, that is software like TexLexan or Alchemy API that can find keywords and other summary information. There is also a good list of open source and commercial solutions on this page. Definitely easier to see if one of those works then writing your own.
I am planning to add weather report for selected country->state->city, for daily, weekly, monthly averages. I have googled it and also went through couple of discussion on stackoverflow threads and I got confused! Could anyone please tell me if there is already Weather report APIs library available? What could be the best way to implement my requirements? I am just expecting overview so that I don't chose wrong path.
Thanks.
See WorldWeatherOnline.
I compiled a set of information about different weather APIs looking for a similar solution. My general consensus was the WorldWeatherOnline seemed to be the best bang for the buck (free) and seemed pretty feature rich.
http://michaelwelburn.com/2011/11/02/comparing-weather-apis/
UPDATE (12/18/2013): This response was from 2011, since that time some different providers have made updates. I tried to keep the link semi-up to date, but you'll want to take the list provided and do your own research.
I am new to GPS.If i send "hotels" in label , any free webservice is available to see them as map?any tutorial please? is there any free webservice to give location name if i give current latitude & longitude values?
Taking your questions one by one :
is there any free webservice to give location name if i give current latitude & longitude values?
This is called reverse geocoding and it's in the SDK already - check out the docs here.
any free webservice available to see them as a map
A quick google search for 'hotels api' found a few results for hotels data feeds like this one.
You will also need to read the documentation for MKMapView - there are a few sample apps linked from that page that it's worth downloading and seeing how they work.
any tutorial please
Google for it - a quick search for 'map kit tutorial' returns this as the first link.
PS One of the best ways to get your question ignored is to ask more than one thing at once - you've asked three questions here and seem to have made no effort to find out the answers yourself first - people generally don't like that (take a look at the comments if you don't believe me!)
If you have more than one question, ask them separately here on stack overflow and give some examples of things that you have tried already :)
Hi I'm doing an RSS reader application but I want the information that shows the iphone on a table can be saved in a DB or a file. Please can someone help me?
Your wording is... challenging, but I think you're looking to store data from your app persistently in a database, yes?
If that's the case, let me introduce you to Google.
If not, then I've just been a minor jackass for no reason, but regardless, please clarify the wording of your question.
There a plenty of tutorials available for SQLite and the iPhone. Please search before asking a question here. Don't think to easy and just ask, try yourself and discover possibilities of the iPhone SDK, SQLite and all other stuff related to it.
We'll only be able to help you if you provide pages/links of all the sources you've consulted.
For what I can do now: please read (and understand/try/adjust it) one of the many tutorials
Navigate over to the Apple site and check out the documentation called "Getting Started With Data Management".
The problem with giving you an exact, step by step answer is that you haven't provided enough information. You might be able to leverage any of the following technologies:
User Preferences
.plist files
Core Data
sqlite database
(these are listed in order of easiest to implement, but least featured at the top to the most robust solution at the bottom)
Based on the comments, I moved Core Data above sqlite