B4A Library Audio Serial Output library

Hello everyone, here's a library to send serial data using the Audio jack, i found this project here.
I decided to give it a shot and port that library to B4A, i haven't fully tested it, you should be able to send serial data over to a microcontroller, you can even use it with the arduino boards, i do not own an arduino board but if you're familiar with serial communication and microcontrollers you should be able to figure this out.
At the moment it is only possible to send data, not receive, the person who created this project is currently working on the receiving part, i will update this library once that part is accomplished.

you can download the library http://www.genesisitdevelopments.com/AudioSerial.zip
and here's an example: www.genesisitdevelopments.com/AudioSerialExample.zip

note that you can change the baudrate, as i mentioned above, i have not fully tested this library, but if you do i would like to hear some feedback.

Updated the link to download the library and the example, see above.

cheers,
Walter
 

Attachments

  • AudioSerial.zip
    51.9 KB · Views: 1,096
  • AudioSerial Example.zip
    335.3 KB · Views: 1,079
Last edited:

walterf25

Expert
Licensed User
Longtime User
Audio Serial Library

thanks vb, i actually tested the library yesterday along with the hardware and it works very nice, this could be uses with IOIO board, and any other system that accepts serial communication!!!

thanks for checking it out!!!
 

raphael75

Active Member
Licensed User
Longtime User
That looks interesting :sign0098:

Is the serial data sent to left or right channel on the audio cable? Is it possible to send different data on each channel? I could not figure it out based on the code example.
 

walterf25

Expert
Licensed User
Longtime User
Audio Serial Library

Yes you can use both channels, left and right to send data, the example provided only uses one channel, i will update the library soon, to allow both sending data over both channels.

If you're interested i tested the library last night along with the hardware and it works great, You will need to build the interface to convert the signal out of the audio jack to TTL levels.

cheers,
Walter
 

walterf25

Expert
Licensed User
Longtime User
Serial Output library

@bluedude, i was referring to this:
Derpserial.png
 

bluedude

Well-Known Member
Licensed User
Longtime User
HiJack

Have you seen this hardware? Maybe you can get it to work with their stuff which is now only for Apple devices.

projects :: hijack

I'm not a hardware guy so all the schematics don't stick in my brain :)
 

automancalibra

New Member
Licensed User
Longtime User
Hi Walterf25
Very interesting library. I will be testing it shortly and will definitely keep you updated.
 

walterf25

Expert
Licensed User
Longtime User
Audio Serial Library

Hi Walterf25
Very interesting library. I will be testing it shortly and will definitely keep you updated.


Thanks Automancalibra, keep me posted and let me know if you have any questions

Cheers,
Walter
 

alexhi

Member
Licensed User
Longtime User
Hello! When I try to download the program to the Samsung Galaxy get error
Compiling code. 0.19
Compiling layouts code. 0.02
Generating R file. 0.00
Compiling generated Java code. 3.38
Convert byte code - optimized dex. 1.50
Packaging files. 3.92
Copying libraries resources 0.23
Found 12 resource files.
Signing package file (debug key). Error

jarsigner: unable to sign jar: java.util.zip.ZipException: duplicate entry: AndroidManifest.xml
What could be wrong? Sorry for my bad English
 

walterf25

Expert
Licensed User
Longtime User
Hey there

Hi there, sorry about that, this was one of my very first libraries, and was just learning how to make them, Thank you Erel for pointing him in the right direction, i will try to update this library later and remove the manifest file.

Thank you!
 
Top