1. [3.1]Can send null (\0 ?) ? [SOLVED]
- Posted by DanM_anew Apr 11, 2014
- 947 views
- Last edited Apr 12, 2014
Is there a way to send a null character (\0)? I'm trying to send a "null terminated string" over USB port to a micro-controller running a C plus plus style program.
Dan M.
2. Re: [3.1]Can send null (\0 ?) ?
- Posted by Fernando Apr 11, 2014
- 926 views
Is there a way to send a null character (\0)? I'm trying to send a "null terminated string" over USB port to a micro-controller running a C plus plus style program.
Dan M.
Hi Dan,
Just append a zero (#00) to the string.
Example:
serial_puts(hCom, "null terminated string" & 0)
- Fernando
3. Re: [3.1]Can send null (\0 ?) ? [SOLVED]
- Posted by DanM_anew Apr 11, 2014
- 907 views
Is there a way to send a null character (\0)? I'm trying to send a "null terminated string" over USB port to a micro-controller running a C plus plus style program.
Dan M.
Hi Dan,
Just append a zero (#00) to the string.
Example:
serial_puts(hCom, "null terminated string" & 0)
- Fernando
Oh! Ok. Thanks!
[EDIT] It worked! And it ALWAYS surprises me when programming things WORK!