HP Forums

Full Version: Connectivity Kit in Mac OS
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello all

I have re-started to (try to) write programs for my Prime, hence my recent questions here.
I am facing an issue which gets on my nerves and would like to know whether someone here already experienced the same problem or not (and eventually has a fix for it).

- I wrote a program at work, in the CK, on a Windows computer.
Check: "No errors in the program"

- Program downloaded from CK to the Prime machine
Check: "No errors in the program"

- Program downloaded from machine to KC, at home, on Mac Book
Check: Error: Syntax Error

Cursor located as below:
EXPORT MOUSE_X,MOUSE_Y(cursor here),other variables....;

Same program, no change, just different contexts.

Any idea?
Should I consider that the Mac Book environment is not fully compatible with the KC?

Kind regards.
Are they all at the same Prime revision level?
Good idea.
The machine was not, it is now. All three (machine, CK and emulator) are now aligned on the latest firmware (2018 10 16).
Unfortunately no more success.
I suspect the "space" character to not be correctly "understood" on the Mac (just a thought).
I will investigate.

Kind regards.
I’ve had a similar problem before when trying to move “plain text” between my Mac and a PC.

If you can, get your program into a pure plain text editor and look for invisible characters.

Remember that the PC uses a line feed and a carriage return to end each line, and the Mac uses only a carriage return.

Finally, if you cannot find anything in the text editor, you might try a hex file viewer, like one that is normally used for looking at files stored on floppy disks. They usually show the file as lines of characters in hexadecimal form, with the ascii equivalent characters to one side.

My bet is that you have an invisible character in there somewhere.

Good luck!

smp
(02-23-2019 01:00 AM)smp Wrote: [ -> ]Remember that the PC uses a line feed and a carriage return to end each line, and the Mac uses only a carriage return.

MS-DOS/Windows: CR LF
Classic Mac OS: CR
Unix/Linux/BSD/Mac OS X: LF
(02-22-2019 09:44 PM)Jean-Michel Wrote: [ -> ]- Program downloaded from machine to KC, at home, on Mac Book
Check: Error: Syntax Error

Cursor located as below:
EXPORT MOUSE_X,MOUSE_Y(cursor here),other variables....;

Same program, no change, just different contexts.

Any idea?

Do you have the same settings for the decimal separator on the different Primes (virtual or physical)?
The error you report is typical of a unit with the comma set as the decimal separator.

The way to avoid this is to insert a #pragma statement at the beginning of the program with the Menu key.
For ex.:
Code:
#pragma mode( separator(.,;) integer(h32) )

See here for more details about #pragma.

Btw, such #pragma statement should part of the default program template when you create a new program, this would avoid a lot of troubles.
The comma settings will be the culprit. One unit is probably set to the eurpoean setting possibly?
The reason for the #pragma setting was explained by a few of us over in this thread also started by you:

http://www.hpmuseum.org/forum/thread-12464.html
Yes, true !
And for this reason it is now sitting on first line of my program.
I will investigate the separator setting, as suggested.
Thanks to all.
After some days dedicated to other more urgent tasks, I found some time for my program, and my first thing was to have a look at the settings of the decimal separator, and bingo! It was indeed the root cause of my pb.
Other exotic settings needed to be corrected also, but with no incidence on this.

Thanks again for you help.
Reference URL's