BASIC

Author Topic: Serial port (COM interface) programming  (Read 11257 times)

Offline Schranz0r

  • Premium User :)
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 5022
  • O Rly?
    • View Profile
Re: Serial port (COM interface) programming
« Reply #15 on: 2018-Nov-19 »
I guess the line:

Code: GLBasic [Select]
buf[(int)nread] = '\0';

should be:

Code: GLBasic [Select]
buf[(int)nread] = "\0";

or:

Code: GLBasic [Select]
buf[(int)nread] = &'\0&';

Only KittyHello can tell...
« Last Edit: 2018-Nov-19 by Schranz0r »
I <3 DGArray's :D

PC:
AMD Ryzen 7 1700 @3.9GHz, 16GB HyperX Fury 3000MHz Ram, ASUS ROG GTX 1060 STRIX 6GB, Windows 10 Pro 64Bit, MSi Tomahawk B350 Mainboard

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10714
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Serial port (COM interface) programming
« Reply #16 on: 2019-Aug-10 »
Fixed. It should be '\0'.