[Implemented] Serial port commands

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
wcardoso
User
User
Posts: 80
Joined: Fri Apr 25, 2003 5:06 pm
Location: Uruguay

[Implemented] Serial port commands

Post by wcardoso »

Please, include native commands to drive the serial port in as many OS's as possible. Commands to send and receive raw data, files and strings; and commands like SetDTR to put the individual port signals on or off. :wink:
with love from Uruguay
GPI
PureBasic Expert
PureBasic Expert
Posts: 1394
Joined: Fri Apr 25, 2003 6:41 pm

Post by GPI »

I think, it is a waste of time, because serial is outdated.
RJP Computing
Enthusiast
Enthusiast
Posts: 202
Joined: Sun Apr 27, 2003 4:44 am
Location: Michigan, USA
Contact:

Post by RJP Computing »

No Way GPI.

You are thinking about it totally wrong. I use serial everyday. Some new USB devices use a serial interface to talk on. So it isn't even close to old dead technology. It is just starting to pickup in my feild. So please let this be a feature that is implimented.
-Ryan
RJP Computing

Ubuntu 8.10/WinXP, AMD Athlon 64 3000+, 1000MB RAM, AC 97 Audio, nVidia GeForce 7600GT 512MB
User avatar
Paul
PureBasic Expert
PureBasic Expert
Posts: 1282
Joined: Fri Apr 25, 2003 4:34 pm
Location: Canada
Contact:

Post by Paul »

GPI wrote:I think, it is a waste of time, because serial is outdated.
Then I would have to say you are not working in an industry that actually sees how widely used com/serial ports are used.

I work in the Television industry and every satellite receiver and controller attached to computer control via COM or LPT port. All the video editor/recorder equipment connects to computer or hardware controllers via COM or LPT.
If I want to transfer data back and forth to my GPS it hooks to computer via COM port. If I want to transfer data or program my cell phone, it hooks to computer via COM or LPT port.

Using your thinking, you would also have to say Satellites and Satellite TV is outdated, moti9on control cameras are outdated, Cell phones are outdated, GPS's are outdated.

COM and LPT control lends itself to so many applications it's mind boggling. I would love to see native COM and LPT commands!!! :)
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6166
Joined: Sat May 17, 2003 11:31 am
Contact:

Post by blueznl »

i would like some serial support as well (as well as usb :-))
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB)
( The path to enlightenment and the PureBasic Survival Guide right here... )
GPI
PureBasic Expert
PureBasic Expert
Posts: 1394
Joined: Fri Apr 25, 2003 6:41 pm

Post by GPI »

blueznl wrote:(as well as usb :-))
For USB-Devices you need a driver, no way without it.
thefool
Always Here
Always Here
Posts: 5875
Joined: Sat Aug 30, 2003 5:58 pm
Location: Denmark

Post by thefool »

i must say that this is needed. Also attached devices to some laptops uses serial interface, as well as other things too.

btW: there should be a new MVCom coming soon!
User avatar
Psychophanta
Always Here
Always Here
Posts: 5153
Joined: Wed Jun 11, 2003 9:33 pm
Location: Anare
Contact:

Post by Psychophanta »

I think this thread is a nonsense, because under certain OSes there is needed kernel wrapper to write/read to physical ports.
http://www.zeitgeistmovie.com

while (world==business) world+=mafia;
RichardL
Enthusiast
Enthusiast
Posts: 532
Joined: Sat Sep 11, 2004 11:54 am
Location: UK

Post by RichardL »

Hi,
I use the serial port for instrumentation, a lot! Many lab instruments have RS232. I am in a team that creates a lot of products that use RS232 for configuration purposes. Our end users like the ability to plug into a standard serial port and go... no drivers to worrry about.

PCs without serial ports can use USB to serial adaptors, I find these work quite well.

Many microprocessors include simple UARTs. Development systems for processors like the PIC family make it easy to use them by supplying library functions that get invoked by a simple compiler directive. (Same for I2C.)

Anyone developing hardware who wants a bit more I/O speed can use chips from FTDI that allow the PC to open a serial port that then talks USB to the chip in the peripheral. (http://www.ftdi.co.uk) The chip provides a simple memory mapped port in the peripherals memory space. This way the PC can use serial functions to talk to a USB device. 1 MByte / second can be acheived.

There is a lot of life still in good old fashioned RS232 :)


Just for interest...
A month or so ago I had to interface a peripheral via the parallel port which later Windows versions does not allow direct access to. I found a utility that punched a hole in the IO permissions map and manged to use my old GFA Basic program that has commands to read and write from the port. The same would work with Pure Basic.
wcardoso
User
User
Posts: 80
Joined: Fri Apr 25, 2003 5:06 pm
Location: Uruguay

Post by wcardoso »

Psychophanta, there is a RealBasic compiler who has a serial communication component and you can compile apps using it.
This compiler can code to Windows, Linux and Mac without any change in the source code. I think this feature will be a very cool thing in the PB compiler, isn't it ?
:wink:
with love from Uruguay
DarkDragon
Addict
Addict
Posts: 2344
Joined: Mon Jun 02, 2003 9:16 am
Location: Germany
Contact:

Post by DarkDragon »

8) I tested the newer MVCom and it is great. There you can get the RI state.
bye,
Daniel
User avatar
geoff
Enthusiast
Enthusiast
Posts: 128
Joined: Sun Apr 27, 2003 12:01 am
Location: Cornwall UK
Contact:

Post by geoff »

I think, it is a waste of time, because serial is outdated.
It's a sad reflection on the IT industry that we consider junking something, not because it isn't useful, but because it isn't cool, or the latest gizmo.

RS232 devices have been in use for 40 years in every application imaginable. Do we scrap billions of expensive equipments just because they have an unfashionable connection? I'm sure hardware manufacturers would love to sell us new versions of everything we own every 5 years, but what's in it for users?

RS232 can be made to work over 100 metres of cheap telephone cable. You are lucky to get USB to work over 5 metres. Does anyone expect USB to be supported in 40 years time?

Sad.
User avatar
Psychophanta
Always Here
Always Here
Posts: 5153
Joined: Wed Jun 11, 2003 9:33 pm
Location: Anare
Contact:

Post by Psychophanta »

wcardoso wrote:Psychophanta, there is a RealBasic compiler who has a serial communication component and you can compile apps using it.
This compiler can code to Windows, Linux and Mac without any change in the source code. I think this feature will be a very cool thing in the PB compiler, isn't it ?
:wink:
??????
If it works on Windows NT, 2000, XP..., then it must include a kernel wrapper to "lie" OS normal user operation.

I've tested MVCOM too. Of course it includes and I/O wrapper if it works on WinNT. It works fine. :wink:
http://www.zeitgeistmovie.com

while (world==business) world+=mafia;
wcardoso
User
User
Posts: 80
Joined: Fri Apr 25, 2003 5:06 pm
Location: Uruguay

Post by wcardoso »

Yes, MVCOM works well on Windows, but what about Linux library ?, or Mac version ?.
I was speaking about a multiplatform version :roll:
with love from Uruguay
Dano
User
User
Posts: 41
Joined: Fri Jul 16, 2004 4:20 am
Location: Edmonton, Ab, Canada

Post by Dano »

One more vote here for native com port I/O support .

And please not just Com1 and Com2, the multiport solutions are becoming more popular.

If Com65 exiss we should be able to see and use it.

Thanks
Post Reply