I'm making an experiment that uses several full length sound files. There must be a way to install them on the SD rather than on the main storage. I've not been able to find a tutorial or code exmaples of how to do this, other than that I need the permission WRITE_EXTERNAL_STORAGE.
Can anybody point me in the right direction?
I'm using Android Eclipse together with Processing, which gives me a little more power (and code completion).
Since today, Processing for Android doesn't show me readable error messages anymore.
I just get this:
BUILD FAILED
C:\Program Files\Android\android-sdk\tools\ant\build.xml:651: The following error occurred while executing this line:
C:\Program Files\Android\android-sdk\tools\ant\build.xml:672: Compile failed; see the compiler error output for details.
I can compile and run working apps on my phone, but if I for example put a call to a non-existing method
foo(); somewhere, it just fails at build without any explanation.
Example that works fine:
void setup()
{
size(displayWidth, displayHeight);
orientation(PORTRAIT);
}
void draw()
{
text("hello world",10,10);
}
Example that gives build error, without telling me where to look.
BluetoothServer, a Processing project that uses the BlueCove Bluetooth library.
BluetoothClient, an AndroidProcessing project that uses Android's Bluetooth libs.
Instructions:
Run
BluetoothServer first, then run
BluetoothClient. They should both send messages when the screen is clicked.
Known issues:
Sometimes, probably because I'm missing an unregister somewhere, the Bluetooth drive seems to crash without telling you. When I can't connect, I usually turn my BT on and off and it works.
I don't usually make stuff for other people but I've really been missing the Bluetooth functionality in my Processing experiments.
Any feedback is welcome! I don't consider myself to be a great coder, so I won't be offended if you point out glaring errors, which I'm sure there'll be many of.
I'm making some quirky project with corrupted JPG files.
I can't seem catch this error the traditional way:
try {
byte b[] = loadBytes("poop"+k+".jpg");
int r = round(random(0, b.length-1));
b[r] = (byte)binaryswap(binary(b[r]));
k++;
saveBytes(dataPath("poop"+k+".jpg"), b);
b = null;
}
catch (Exception e) {
println("We went too far Jack, he's done for!");
}
...Doesn't ever enter the Exception branch, although the following is displayed in the console:
Corrupt JPEG data: bad Huffman code
... or...
Corrupt JPEG data: premature end of data segment
I'm working with corrupt files, actually they are being corrupted by the program. I want to know when they get corrupted so I can act on it... but how do I catch the error?
I'm trying to send data from my android to my PC. I didn't find much help in the forums or online, all I found was OSCP5 which seems to work (got some examples running) but feels strange as its a library intended for sound if I understand correctly.
Just sending messages back and forth is all I need.
Is there any other android NET/Socket libraries out there that I missed?
Is processing not something I should use if I want to do networking?
I just started using Processing today and I remade Atari 2600 Pong for android, trying to stay as true to the original as possible, but with swipe controls for 2 players. It works great in dev-mode.
Now I wanted to sign it and I ran into some troubles.
- I exported the package from processing
- I created a keystore
- I built it with ANT
- I ran jarsigner on the 'unsigned.apk'
...
it returns a bunch of filenames and then nothing, no error.
But the package remains unsigned.
I'm not sure if this has anything to do with Processing, but it would be great if you guys can push me in the right direction. I think Atari Pong is a pretty sweet first app to write in Processing, but in this way I can't share it with anybody :(