Love2D "Serial Port Communication"

Showcase your libraries, tools and other projects that help your fellow love users.
Post Reply
User avatar
BruceTheGoose
Citizen
Posts: 76
Joined: Sat Sep 20, 2014 2:54 pm

Love2D "Serial Port Communication"

Post by BruceTheGoose »

I managed to interface my Arduino Uno with Love2D with a bit of Java.

Here is a demo:

https://www.youtube.com/watch?v=LVhdxpY ... e=youtu.be
"I don't know."
User avatar
Davidobot
Party member
Posts: 1226
Joined: Sat Mar 31, 2012 5:18 am
Location: Oxford, UK
Contact:

Re: Love2D "Serial Port Communication"

Post by Davidobot »

Really cool stuff right here!
Any walk-throughs of how to do this?
PM me on here or elsewhere if you'd like to discuss porting your game to Nintendo Switch via mazette!
personal page and a raycaster
User avatar
BruceTheGoose
Citizen
Posts: 76
Joined: Sat Sep 20, 2014 2:54 pm

Re: Love2D "Serial Port Communication"

Post by BruceTheGoose »

Davidobot wrote:Really cool stuff right here!
Any walk-throughs of how to do this?
I'll make one later. Stay tuned!
"I don't know."
SPlice
Prole
Posts: 48
Joined: Thu Jul 28, 2011 8:53 am

Re: Love2D "Serial Port Communication"

Post by SPlice »

I have been hoping they would add serial support to love. I am told that it can be done with IO or something but I have never gotten it to work without the middleman program to read the serial data and send it through UDP to love.
cval
Citizen
Posts: 58
Joined: Sun Apr 20, 2014 2:15 pm
Location: Ukraine

Re: Love2D "Serial Port Communication"

Post by cval »

As a microcontroller enthusiast i'm interested in this kind of thing. Does it use ffi? Or love script communicates to some other application as client?
Nathan1852
Prole
Posts: 2
Joined: Sat Mar 08, 2014 9:18 pm

Re: Love2D "Serial Port Communication"

Post by Nathan1852 »

You might want to take a look at this: https://github.com/cbrake/LuaSerialPort
It worked perfectly for me
cval
Citizen
Posts: 58
Joined: Sun Apr 20, 2014 2:15 pm
Location: Ukraine

Re: Love2D "Serial Port Communication"

Post by cval »

Well, so it actually depends on FFI doesn't it? (=
And with Java mentioned i thought that Java-coded application sits on a VCP (that is created by USB-TTL chip on an Arduino) and then sends data over network to love2d. Nice anyway, i'm thinking about making some kind of IRL HUD for a game or maybe something else.
User avatar
Positive07
Party member
Posts: 1014
Joined: Sun Aug 12, 2012 4:34 pm
Location: Argentina

Re: Love2D "Serial Port Communication"

Post by Positive07 »

I found this library which works amazingly well, I had to make some changes to compile it, since the associated dll for Lua didn't have the same name as LÖVE's one but it was not that hard, I have an outdated .dll somewhere if someone is interested, and I would love to have an updated version since I would found it really useful
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 65 guests