How to set up BeagleBone Black to stay off - beagleboneblack

Please, I have a question about BeagleBone Black. Is there a way how to configure BBB to stay off when power is connected? There is the power button for soft power off. It can be used to power on after BBB is turned off. But BBB always start immidietly when the power is connected. I need it to stay off and wait for the button pressed.

It can be done using some hardware modification of Beagle-bone board.
At SYS_RESETN pin Reset Min Push Botton must be replaced with Toggle Switch.
When switch is on state the SYS_RESETIN connected to GND(0 V). The device will not stated till SYS_RESETIN pin is connected to GND(0 V).
When switch is off the SYS_RESETIN will be coneected to VCC(3.3 V)
Now, the device will operate normally.
The schematic can be found here.
Hope, This will be helpful to you.

Related

How to wake up Nvidia Jetson TX2 from suspend mode?

Every time I put it in suspend, I have to restart it. I tried clicking keyboard and mouse buttons, but no luck.
I also tried pressing reset, power and recovery button on the device. Power just restarts the device instead of recovering from the suspended state.
Please help.

Get input of switch control via headphone jack on iOS

As a little holiday project I want to control an app via an accessibility switch which is connected via 3,5mm headphone jack to the iOS device.
This is the switch and the plug:
My problem is that I don't have any clue what kind of signal is fired when I press the button - I assumed that it acts similar to a headphone's remote control.
Is there a way to measure the input of this or does anybody know how to get the input of the button on iOS?
Your button is a "Big Buddy Button Switch," designed by AbleNet for persons with moderate to severe upper extremity and motor disabilities. It is not designed to plug into an IOS device nor into any mobile tablet or phone.
There is an "Hook + Switch" interface ($185 at this moment) that is designed to go between this button and an IOS device, allowing connection of two such buttons to the lightning connector. When connected in this way, the button press can be detected and mapped to many different kinds of IOS actions using apple accessibility settings. That's a lot of money, but since new iphones don't even have audio jacks it may end up being worth it.
A link to your button is here.
A link to the Hook+ Switch Interface is here.
A link to Apple information on accessibility switches is here.
The Big Buddy Button is a passive momentary action switch. The mono TS plug attached is connected internally to the momentary action normally open switch, so pressing the switch will short TIP to SLEEVE.
Plugging this TS plug into an ios device designed to receive a TRRS plug will short RING1 and RING2 and SLEEVE together even when the button is not pressed, which will not accomplish anything useful. Pressing the button will further short TIP to RING1 and RING2 and SLEEVE. There is no way to read such a button press from ios internals if the TS plug is plugged in directly.
If you want to hack together a solution that will work for many mobile devices (e.g., android) you can do so simply by replacing the TS plug with a TRRS plug (or wiring up an adaptor) as follows:
One of the two Big Button conductors should be connected to the SLEEVE, which carries power (for a microphone) and is the source of the voltage that is sensed internally for volume changes and switching. The other Big Button conductor should be connected to RING2, which is the ground line for both earbud channels and the microphone. Nothing should be connected to TIP or RING1.
Pressing the Big Button will momentarily short Sleeve to Ring2, which is the same as pressing the switch on an earbud cable. If you wanted to simulate a volume up or volume down command, you would connect a resistor in series with the button (220 ohms for volume down, 600 ohms for volume up).
The electrical connections for the audio jack are the same for iOS devices as for Android, but there's an extra hurdle you must get over if you want to connect up buttons and have them be detected within iOS. As part of their MFI (Made for iPod/iPhone) program, Apple uses a startup recognition chirp sequence when anything is plugged into the audio jack (or the lightning connector). Your device must have the correct chip inside it (or emulate the behavior of that chip) or else the button controls interface will be disabled when you fail to respond to the authentication request. The protocol seems to have changed over time, because aftermarket products that worked with one model of phone did not always work with another. Apple insiders have stated that the MFI chips contain a serial number that Apple can read upon connection. They say that reverse-engineered authentication works today, but that Apple could prevent it from working at any time.
If you want to design this as a product, you can apply for the MFI program here.
If you just want to build a handful of devices, you won't be able to get accepted into the MFI program. In that case you'd need to purchase the Hook + Switch interface (or something like it) or else you'd need to add a small microprocessor like an Arduino or a Teensy to emulate the authentication chirp, as David Carne did here.
If you just want to build one working button, the easiest way would be to use an existing pair of headphones that contain the necessary chip, and simply put your button wires in parallel with SLEEVE and RING2. If I were doing this I'd get a TRRS extension cord and splice the Big Buddy Button wires to the correct two wires of the extension cord. Your Big Button should work so long as a pair of apple-certified headphones are plugged into the extension to provide the authentication. You would then detect the button press as usual (described here).
EDIT: I tested connecting an accessory button to SLEEVE and RING2 of a TRRS extension cable that's plugged into the iPhone, and as long as a functioning headset is
plugged into the extension cable, the accessory button does work. This way the
accessory button ends up in parallel to the built-in button, without
having to cut apart the headset.
There are other alternatives you could pursue. For example, you could build a circuit that transmits a mic-level tone across the two conductors whenever the button is pressed. You'd then plug that signal into the iOS device between SLEEVE and RING2, and then write an iOS program to listen for the sound and treat it as a button press. MFI authentication would not be needed for this approach, and there are existing utilities that would get you 90% of the way there. You can find an example here.
It's also possible to connect to iOS through BLE without signing up for MFI, and since Apple Accessibility includes the ability to use a bluetooth device to control certain iOS functions, you may be able to do this without needing authentication.
An image showing the connection schematic for TRRS connectors on most mobile devices (including iPhone) is here.
Reproduced here for convenience.
Function/Mic == SLEEVE
Common/Gnd == RING2
Right/R+ == RING1
Left/L+ == TIP
If it was as headphone jack, you can handle it using
override func remoteControlReceived(with event: UIEvent?) {}
and toggle inside of it event?.type.subType something like this.
override func remoteControlReceived(with event: UIEvent?) {
if let e = event , e.type == .remoteControl {
if e.subtype == UIEventSubtype.remoteControlPause {
// do something
}else if(e.subtype == .remoteControlPlay){
//do something else
}else if(e.subtype == .remoteControlTogglePlayPause){
// do something else
}
}
}
Apples wired 3.5 mm headphone with volume control have 4 conductors. In your picture I see only 2 conductors. So your switch can't be sending the Apples's own headphone remote commands - since the the microphone ring for sending data is missing.
I'd guess your switch just makes contact between the two conductors.
Here is what I would do.
Verify with a multi meter the resistance of your switch in the open and closed position.
I'd expect on close the resistance is low or close to zero.
Now find an (old) pair of Apple 3.5 mm headphones with volume control. Disassemble the volume control of the headphones and solder your accessibility switch to the volume control pads. Now your accessibility switch simulates pushing the volume control.
Alternatively look at http://david.carne.ca/shuffle_hax/shuffle_remote.html
So use a micro controller to simulate the headphone volume control and use your accessibility switch to control the micro controller. It looks like a fun project - enjoy.

Trigger camera shutter on iPhone from Macbook

I'm writing a script on my macbook to trigger the camera shutter on my iPhone.
I'm struggling to understand how to do this programmatically. I've tried:
Using macbook as bluetooth keyboard (don't know how to simulate a volume press)
Using "Switch Control" functionality on Macbook to control the iPhone device (unfortunately it seems like the simulated keypresses don't get sent over to the iPhone)
Any other ideas would be greatly appreciated !
You're close! While a bit of a kluge, you can connect a Bluetooth keyboard to your phone, enable Switch Control on iOS, and bind a key to the "Increase Volume" action. If that doesn't work, you can always bind keys to the "Move to Next Item" and "Select Item" actions, and then then move through the interface one element at a time until you reach the shutter button.

Default keyboard is not coming when Barcode Scanner Device is Connected by Bluetooth in IOS

I am facing issue with keyboard when barcode scanner device is connected using bluetooth.
Flow:
1) I have turned on Bluetooth, and connected barcode scanner device using bluetooth by entering displayed code in it to connect.
2) I am able to use scanner, but the default keyboard is not displaying even we call becomeFirstResponder.
3) When I disconnect the scanner device or turn off bluetooth connectivity then the keyboard is coming.
Note: Below is the link for the Barcode Scanner device i am using
Barcode Scanner Device Information
Anyone faced this kind of issue?
Please suggest how to fix this issue.
Thanks in Advance..!
This solution only works on Ipad. when the soft keyboard disappears just press and hold the down arrow on the bottom right of the screen and the soft keyboard will be back.
We are clear and there is no question that Bluetooth Scanner is pretending to be a Bluetooth keyboard, so iOS thinks that it does not need to show the on screen one.
For Barcode Scanner type socket mobile are now adding a feature to open the iPad onscreen keyboard. For example, the Socket CHS has a new button press option. You can check if your device have the same functionality*(It is likely to be of some help)*
Bring Up the Virtual Keyboard With a Real Keyboard can be a good idea.
When you have a Bluetooth keyboard connected to your iPad, the virtual keyboard will cease to appear. (This is a good thing.) However, what if, for some random reason, you needed that virtual keyboard? Don't unpair your Bluetooth. Just... Hit the eject key on Apple's physical keyboard. It'll bring up the virtual one.
There is another way to try to solve this, personally I tried it and it was very unstable. Taking into account that it is a kind of hack, expected unstable behavior.
This answer to a related question (https://stackoverflow.com/a/3837131/493988) has what seems like a hack based on a UITextField's inputAccessoryView.
Even the user #Kurt Arnlund in this answer mentions a external app called KeysPlease link here. I really have not tried it, you can try.
In summary, there seems to be a clean way to solve this, I think these may be the best attempts to reach a solution
Sources:
Bluetooth Scanner sets system-wide keyboard, UITextFields wont show soft keyboard on responder
Force on screen keyboard to show when bluetooth keyboard connected
Show iPhone soft keyboard even though a hardware keyboard is connected

Is there any way to keep touches alive in iOS?

I'm testing the touch detection capabilities of the iPad (specifically iPad 3 at the moment). I'm printing out a log of detected touches to see what is going on, and using a bottle with three foam (touch friendly) pads at the bottom.
The touches are detected fine and it logs any slight movements which is great. The issue is that after a while if the bottle isn't moved at all, all three touches are forcibly cancelled and remain undetected until the bottle is removed and placed back down.
So it seems there's a timeout on these touches... I have not found any specific information on this. Is there any way to revive or keep alive touches without having to physically remove and restore your touch points?
A capacitive touch sensor is a very sensitive instrument, and a lot of filtering is done before the OS reports touches to you. This is also the reason why the iPad cannot detect touches with smaller contact areas than what comes with cheap styli - rubber domes of about 7mm diameter. The touchscreen controller detects smaller touches alright, but filters them to avoid spurious signals. Note that the touchscreen of a Samsung Galaxy will already detect touches with a dull pencil - the screen is (for practical purposes) the same as that of an iPad, but the cutoff for the controller is lower.
I would expect that the self-calibrating logic inside the touch controller will calibrate your touches away. Basically, it will set the signal produced by your foam pads as the new normal. On the application side there is nothing that you can do to reverse this.
Disclaimer: I have no inside knowledge of what goes on inside the touchscreen controller. My answer is based on much reading and solid reasoning, nothing more.

Resources