How to print from iPad using bluetooth? - ipad

I have a printer which supports the printing over the bluetooth network .
I searched for printing from iOS and went through the Apple documentation on UIPrintInteractionController class . But no where it has been specified whether it can use bluetooth to make the connection to the printer or not ? I know it works on the Wifi .
Can any one suggest any tutorial or any link on printing from iPad using bluetooth ( if at all possible )
Please help me with this !!!!

The AirPrint protocol uses a WiFi network to detect compatible devices. I don't think it's possible to print via Bluetooth in iOS as of yet.

Related

How to send data to apple tv app from my iphone

I'd like to know if there is a way to send some data from my iphone to my apple tv.I'll explain:I want to make an app for my apple tv and extend this app to my iphone.Using the extension in running on the iphone you should send some data to my app in running on my apple tv.Sending data it should not be through wi-fi but using for example the bluethoot.How should I do to build this comunication?Can you explain to me how to do or link me some resources?Thanks to all!
Ps. sorry for my english!
The MultipeerConnectivity framework should allow you to do this. It's available in the SDK and supported by both tvOS and iOS.
The advantage is that you don't have to chose what type of connection the devices use. It supports both WiFi and BT. But if you don't want to use WiFi because wifi is not available, it can by default create a peer to peer wifi network between devices.
https://developer.apple.com/reference/multipeerconnectivity
And also, here https://www.hackingwithswift.com/example-code/system/how-to-create-a-peer-to-peer-network-using-the-multipeer-connectivity-framework is a good tutorial.

Is it possible to create an iOS app that communicates wirelessly with an Arduino device?

Like the title says, is it possible to create an iOS app that communicates wirelessly with an Arduino device, whether it's bluetooth or wifi, etc?
As an addon question, can bluetooth or wifi work through materials such as thick plastic?
You can either user bluetooth or wifi direct for the wireless communication . Apple provided rich apis for these framework.
For wifi direct there is framework called Multipeer Connectivity . You can find documentation : https://developer.apple.com/library/prerelease/ios/documentation/MultipeerConnectivity/Reference/MultipeerConnectivityFramework/index.html
For Bluetooth there is framework called Core Bluetooth , you can find the documentation :
https://developer.apple.com/library/ios/documentation/NetworkingInternetWeb/Conceptual/CoreBluetooth_concepts/AboutCoreBluetooth/Introduction.html

Bluetooth iOS printing on Bixolon SPP-R200II

We are users of POS printer Bixolon SPP-R200II which we use for realisation of one of our projects. In the specification of this model it is listed that printer supports printing on iOS devices (iPhone & iPad) but until now we have not succeeded to achieve that. We switch the printer onto iOS mode with a required combination we fonud in official documentation and we got confirmation message. Then we connected to the printer from bluetooth interface inside iPhone Settings app.
After that we tryed to print on this device in various ways - using official test app from AppStore (https://itunes.apple.com/us/app/bixolon-printer-utility/id647125968?mt=8) and using official Bixolon SDK (http://www.bixolon.com/upload/download/software_all_bixolon_printer_sdk_for_ios_v3.1.8.zip) but unfortunately we havent managed to get any result. In this sample apps printer was not even listed as a possible connection point.
Can you direct us in any way to get the printing on iOS devices working? Thank you!
To connect to the SPP-R200II you need to enable MFi Mode for the printer.
Turn on printer
Open the cover and press the power button and paper feed button at the same time for 2 seconds
Close the cover when the buzzer sounds
The printer should now print "iOS mode enable!!" [sic]. If not, you just turned off MFi mode and need to repeat the steps to turn it on again.
Unfortunately the sample application distributed with the Bixolon SDK 3.1.8 is broken and when you press "Lookup/Targeting" nothing will happen. To fix it add this line to didFindPrinter in ViewController.h:
_uiTextFieldAddress.text = [NSString stringWithFormat:#"BT_%#", printer.macAddress];
It should now be possible to connect the printer simply by pressing "Lookup/Targeting" and then "Connect" when you se the Bluetooth address in the text field.
We had the same problem and after contacting technical support, concluded that the model we have is not compatible with iOS, the part number must be 3 letters i, for example SPP-R200IIIK/USA. After making the switch equipment provider, everything works perfectly.
Is the printer paired with the device in settings? It must be paired before the application can interact with it.

Connect and Disconnect USB Cable to iPhone using IOS programming

I am developing a iPhone app like " Eject device" on computer. which means, when I connect USB cable for connecting to computer, this application just disconnect that connection by a single Click. I was googled about this, and I got some idea about EAAccessoryManager . this EAAccessoryManager only for notification. when USB cable connects or disconnect it can notify to the user. But I need to disconnect connection programmatically . is there any API or Tutorial available for this ? Kindly help me please.
You should probably look at IOKit. I believe IOKit works with USB device both on iOS and OS X.
You may be interested to take a look at these link:
https://developer.apple.com/library/mac/#documentation/DeviceDrivers/Conceptual/USBBook/USBIntro/USBIntro.html
http://iphonedevwiki.net/index.php/IOKit.framework
Also, there is very good book on iOS/OS X kernel and I believe there is a whole chapter regarding IOKit:
http://www.amazon.com/Mac-OS-iOS-Internals-Apples/dp/1118057651
You can find the private API for the iOS Frameworks in https://github.com/kennytm/iphone-private-frameworks, but I don't think that this capability is present. The reason I think this is because there is no reason to want to do this from the iPhone, and therefore no reason for Apple to include it in the API.

Send midi note on/note off with velocity over wifi from iPad

Does anyone have example with iOS/Objective C, on how to send midi "note on/note off" signal (with different velocity) over wifi so that iPad would display in "Mac OS X->Audio Midi Setup->Network. then I click connect device" and by simple touching on the button on iPad code will send midi command. I believe I need to use some protocol,but I'm newbie on this, please help me.
Thanks.
You have to use the coremidi framework (provided by the IOS). See here for a introduction: http://www.synthtopia.com/content/2011/06/02/coremidi-brain-dump/
If you are still looking I wrote sample code that is on GITHUB that wirelessly sends/receives MIDI notes ON/OFF messages from iPhone/iPad to Windows PC, Apple Mac or any other device listening. Full instruction on GITHUB.
see: https://github.com/JohnGoodstadt/MidiNotes

Resources