Hi,
I discovered Godot recently and after some research, it is appear that GDScript do not have class/object/API to control Serial port (ttyUSB0/COM1/...).
It may be interesting to implement this to create custom hardware interfaces (e.g: made with arduino).
Is it possible to implement an API like that ? As an alternative, I suppose there is C # or python (beta?) but being able to use only GDScript in development would be better.
If you want it working now, try using https://github.com/StraToN/godotosc (gpl) https://github.com/djiamnot/gdosc (mit) and https://github.com/CNMAT/OSC.
The first two are a godot implementation of OSC and the other goes on the hardware (arduino) for OSC control.
Just clearing a confusion: support for something like that is independent of the scripting language (GDScript, C#, Python, anything else). It has to be implemented as a native API bound to scripting languages, either as a module (C++) or via GDNative (C, C++).
@fire thank you for your help. Looking to your link, it is seem to work only with UDP socket ? i am wrong ? I prefer wait a full serial support (if possible). It will allow my application to update the 碌C firmware through the serial usage.
@akien-mga thank for the clarity. The usage of a C++ serial library for godot will not be too complicated to integrate then ?
See this section on slip based serial internet. https://github.com/CNMAT/OSC#receiving-data for communication over serial.
@Zaltora There is already a gdnative implementation: https://github.com/Superwaitsum/GDSercomm
Since the issue was filled, there may be a chance to integrate it in godot? :wink:
@fire Thank you, nice to know ! I will maybe use it. Use Serial with SLIP feel like a good idea.
@Superwaitsum Great, it is an external library to download ? Yes integrate it in godot can be nice !
@Zaltora It's a GDNative implementation, you can download an example project here:
https://github.com/Superwaitsum/GDSerialAsset
Feature and improvement proposals for the Godot Engine are now being discussed and reviewed in a dedicated Godot Improvement Proposals (GIP) (godotengine/godot-proposals) issue tracker. The GIP tracker has a detailed issue template designed so that proposals include all the relevant information to start a productive discussion and help the community assess the validity of the proposal for the engine.
The main (godotengine/godot) tracker is now solely dedicated to bug reports and Pull Requests, enabling contributors to have a better focus on bug fixing work. Therefore, we are now closing all older feature proposals on the main issue tracker.
If you are interested in this feature proposal, please open a new proposal on the GIP tracker following the given issue template (after checking that it doesn't exist already). Be sure to reference this closed issue if it includes any relevant discussion (which you are also encouraged to summarize in the new proposal). Thanks in advance!
Most helpful comment
@Zaltora There is already a gdnative implementation: https://github.com/Superwaitsum/GDSercomm
Since the issue was filled, there may be a chance to integrate it in godot? :wink: