Need some advice on C++ Server for iPhone apps - iphone

I need some help with finding some tutorials on how an iPhone communicate with a C++ based server. I have been searching online for a while and have not found the suitable site. I may have keyed in wrong keywords in the search, so I am asking here if anyone knows how I can learn this?
Any help would be greatly appreciated.

I think that you are asking the wrong question.
Instead, try to learn how to interface with your C++ server abstractly. This will lead you to a set of steps to do so, such as "open a TPC socket to port XYZ" or "Resolve a CORBA object reference to BlahDiddyBlah".
Then, once you know how to walk, learn how to walk on iPhone. Googling "iPhone TCP socket tutorial" will be much more productive than Googling something half-under-specified and half-over-specified. (The "under" half being how does the server connect, the "over" half being that it's written in C++)
So step one, figure out how one connects to the server from any sort of program.

Related

How to create owner/server for booking app

Guys really need your help I’m a beginner and don’t have any idea on how to create a owner or server for my project (photography booking app) I already started to create a client apps to make a log in or create a request/ book.. but how can I make a server or owner app who can see the request from client app. Can you please give me a tips or instruction not only on how to do it but the most is to understand how it really works Thanks in advance .
You've not really provided much info to go off (for example, what if any languages you're already comfortable using). There's probably too much to cover to explain here.
That said, for creating a backend, I personally found Flask pretty light and simple to get started with. There's also a really excellent tutorial series on it here: https://blog.miguelgrinberg.com/post/the-flask-mega-tutorial-part-v-user-logins
Maybe start here?

How to connect HC-05 to MSP430

I am trying to use Bluetooth module HC-05 with MSP430 by Texas Instrunments.
I want the bluetooth module to collect data wirelessly from an android phone via bluetooth. Can anyone please help me?
You will find an answer and the end. But first I need to write a few introducing words.
You are new to SO and, you might wonder why no one answered your question.
If I should guess: IMHO there could be two main reasons for this.
Your question is not specific enough:
What kind of TI MSP430 do you intend to use? I suppose you use a launchpad G2(?).
What have you tried so far? You can not expect someone else to invest some time if you did not try so solve your problem yourself. Perhaps it easy, if you only try. The people here love to help, but they expect you to be interested in the problem.
What is your backgroud: Are you a programmer but do not know how to connect the hc05 to the MSP or are you fit in electronics and connecting MCUs? Are you a complete beginner?
There are so much cases and I would not have the time to handle all.
I used google to search "MSP430 HC-05" and found a lot of usefull stuff. The first hit is a project working with a Energia IDE, a HC-05 module, a G2-Launchpad and even an Android phone. I and probably other people do not understand why you did not try to search the internet for information.
Ok! enough wise words! ;-)
Here is the promised answer:
You find an example project with the following URL: http://www.electronicwings.com/ti-launchpad/hc-05-bluetooth-module-interfacing-with-msp-exp430g2-ti-launchpad
More results can be found: including (Youtube) Videos
- Keywords: HC-05 MSP430
Please try to work with that material and feel free to ask furter questions here.
But please be sure to be a bit more specific. (Code examples, error messages, your configuration and hardware and what you've tried so far.)
Cheers PPK

SoftPhone and linux

We are thinking about writing a softphone app. It would basically be a component of a system that has calls queued up from a database. It would interface with a LINUX server which has Asterisk installed.
My first question is
Whether we should write the softphone at all or just buy one?
Secondly, if we do,
what base libraries should be use?
I see SIP Sorcery on CodePlex. More than anything, I am looking for a sense of direction here. Any comments or recommendations would be appreciated.
The answer would depend on the capabilities you have in your team and the place you see your core value and the essence of the service you provide.
In most cases, I'd guess that you don't really care about SIP or doing anything fancy with it that require access to its low level. In such a case, I'd recommend getting a ready-made softphone - either a commercial one or an open source one. I'd go for a commercial one, as it will give you the peace of mind as to its stability and assistance with bug fixing and stuff.
To directly answer your question, one of the many open source softphones are likely to fit your needs, and allow slight modifications as needed. Under most open source licenses there is no obligation to distribute your code as long as you only use it internally (do not distribute the binary.)
Trying to guess what you are trying to do, it sounds like a call center like scenario, so one of the many call queue implementations out there might fit your needs.
I had to write an own softphone and I found a great guide how to achieve it. In the guide there are 10 steps provided for having an own softphone (voip-sip-sdk.com on page 272)
I found it useful and maybe you will find it as well.

Most effective way to do networking on Mac/iPhone?

What would be the most effective way (that is, best ratio of effort vs readability and maintainability) to establish TCP connection or send UDP datagrams on Mac and iPhone? I'm very familiar with classic BSD sockets, but I'm not aiming for portability right now; I'm just trying to be quickly done with a small project.
I'd love to have an Apple-provided Objective-C wrapper, but I'd like to hear some thoughts on what people are commonly doing. If you think BSD sockets are the way to go, feel free to punch in some thoughts, too: I'm really just interested in finding the "right way" to do it.
Let's presume the protocol to be a custom one, so our needs cannot be serviced by the Cocoa-based HTTP client classes :)
My current aim is to stream device status (e.g. accelerometer) over the network over UDP while also maintaining signaling and delivery-guaranteed-event (e.g. button pressed) connection over TCP. A desktop application would display this status.
However, my current application is just what made me ask the question; I'm wondering what people generally do. When I last seriously worked with VB6 about 7-8 years ago, WinSock ActiveX control did things a bit different than what is done with BSD sockets, no matter what it did under the hood.
For networking, the simple answer is,
(1) ASIHttpRequest ........ NOTE - this QA is very old. Unfortunately ASIHttpRequest is of historic interest only and is no longer available.
(2) AsyncSocket
(3) When you're starting out ... GameKit (a child can use it)
(4) Just use Bonjour (two lines of code) to find other devices.
"an Apple-provided Objective-C wrapper" ... AsyncSockets (written originally by the mysterious Dustin J. Voss) is SO GOOD that Apple just won't bother trying to write one!
AsyncSockets is exactly what you're after. It is used everywhere in the 300,000 iFone apps. It "is" networking on the iFone. Hope it helps.
AGAIN NOTE - this QA is very old. You can easily now find "modern versions of" software like AsyncSockets.
BTW, it's worth nothing that there is absolutely nothing wrong - at all - with just using GK .. the performance can be spectacular. About the only downside is that pairing simply takes a plain long time with GK. And it's a childish mess created for ten year olds learning programming. You will be able to do 100x faster pairing working directly with AsyncSockets.
You may prefer to use some toy GK code, while you figure out Bonjour and all that.
I would suggest the consensus of opinion is that there is no point working at an even lower level (ie, raw sockets) than AsyncSocket .. there's not much more performance to be had in there.
NOTE - if you are new to gamekit / iOS be sure to read this critical tip!
Client/Server GKSessions
hope it helps.
Your question can't really be answered with any detail because you haven't described what you want to do. The best answer I can give is to read the introductory networking guides for Mac and iOS.
Update
I don't think there's any "easy Cocoa way" built in for UDP. I recall this discussion has come up several times on the cocoa-dev list. The cocoaasyncsocket project has been mentioned various places. It claims:
AsyncUdpSocket is a UDP/IP socket
networking library that wraps
CFSocket. It works almost exactly like
the TCP version, but is designed
specifically for UDP. This includes
queued non-blocking send/receive
operations, full delegate support,
run-loop based, self-contained class,
and support for IPv4 and IPv6.

MSN API for Objective-C

I would like to know whether if there is any Objective-C MSN API. I have searched for a while and could not really find one.
And if not could somebody tell some good place to look to start the protocol from scratch. Some points on how to start with.
I found this site mentioning details about the protocol. But still not sure how to start with.
http://www.hypothetic.org/docs/msn/index.php
Thank you and Kind Regards,
Tharindu
I think you might be out of luck. MSN is proprietary so APIS are going to be thin on the ground and those that exist will be reverse engineered.
Having said that, Pidgin is an open source IM client that supports MSN. You could use its core library (libpurple) which is written in C and hence compatible with Objective-C.