I recently installed PureBasic 4.60 demo on an iMac running Mac OS X 7.2 Lion.
It's basically working but the OpenConsole() command does not work. Then looking at the forum I saw it mentioned that this feature is not available on the Mac version.
I am looking for a basic to run on a mac to control stepper motors out the USB port. If the console command does not work what other options do I have?
Otherwise this seems like a deal breaker and I need to look for another basic. I chose PureBasic for evaluation, liking it since it ran on a Mac.
Mac OS X and OpenConsole()
Re: Mac OS X and OpenConsole()
Hello and welcome to the PureBasic forumsjermcf wrote:I recently installed PureBasic 4.60 demo on an iMac running Mac OS X 7.2 Lion.
It's basically working but the OpenConsole() command does not work. Then looking at the forum I saw it mentioned that this feature is not available on the Mac version.
I am looking for a basic to run on a mac to control stepper motors out the USB port. If the console command does not work what other options do I have?
Otherwise this seems like a deal breaker and I need to look for another basic. I chose PureBasic for evaluation, liking it since it ran on a Mac.

Do you really need to open a console or do you just need the "Runprogram" command to control the stepper motors by calling a commandline program?
Re: Mac OS X and OpenConsole()
Thanks for the comment.
I will look into using the command line.
I will look into using the command line.
Re: Mac OS X and OpenConsole()
you can kind of fake the console() with the EditorGadget
Code: Select all
If OpenWindow(0, 0, 0,817, 817, "EditorGadget", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
EditorGadget(0, 8, 8, 800, 800,#PB_Editor_ReadOnly)
lin.l=0
i.l
For i=1 To 10
AddGadgetItem(0, lin, Str(i)+" = "+StrD(Sqr(i)))
lin+1
Next
Repeat : Until WaitWindowEvent() = #PB_Event_CloseWindow
EndIf
End
Re: Mac OS X and OpenConsole()
In the documentation it "says" OpenConsole() works for All platforms ... is this a new problem on the Mac or has it never worked?
Even the "Platform-dependent Functions" page in the doc implies this command should work on OS X ...
Even the "Platform-dependent Functions" page in the doc implies this command should work on OS X ...
Re: Mac OS X and OpenConsole()
It make not sense to use the console on Mac, because it's not the same as on Windows.USCode wrote:In the documentation it "says" OpenConsole() works for All platforms ... is this a new problem on the Mac or has it never worked?
Even the "Platform-dependent Functions" page in the doc implies this command should work on OS X ...
OpenConsole() is working on Mac.
Open the console directly - it's a tool - and you can work with it. All outputs are shown, inputs will react (?). Try a small snippet to test it.
But the console in Mac is used for a lot of outputs , as you can see, so it makes no sense to use it often.
michel51
Mac OS X Snow Leopard (10.6.8 ) Intel
PureBasic V 5.21(x64), V 5.22beta
Mac OS X Snow Leopard (10.6.8 ) Intel
PureBasic V 5.21(x64), V 5.22beta
-
- Enthusiast
- Posts: 536
- Joined: Mon Feb 16, 2009 10:42 am
- Location: sweden
- Contact:
Re: Mac OS X and OpenConsole()
Wow there. stop time for a second....
Terminal in Mac OS X... This is basicly "console", now isnt it?
I wouldnt be surprised (but have no desire to test) if the print() commands etc works fine for console output.
Terminal in Mac OS X... This is basicly "console", now isnt it?
I wouldnt be surprised (but have no desire to test) if the print() commands etc works fine for console output.
Re: Mac OS X and OpenConsole()
No! Console and Terminal are two different tools.jesperbrannmark wrote: Terminal in Mac OS X... This is basicly "console", now isnt it?
Terminal is like a "command line" tool, which you cannot use for inputs and outputs from PB.
Run the 3 line code in openconsole(), open the console on your Mac (programms/tools/console) and see the last line.
It is like it is! The console commands are not usable on Mac.
michel51
Mac OS X Snow Leopard (10.6.8 ) Intel
PureBasic V 5.21(x64), V 5.22beta
Mac OS X Snow Leopard (10.6.8 ) Intel
PureBasic V 5.21(x64), V 5.22beta
Re: Mac OS X and OpenConsole()
michel51,michel51 wrote:No! Console and Terminal are two different tools.jesperbrannmark wrote: Terminal in Mac OS X... This is basicly "console", now isnt it?
Terminal is like a "command line" tool, which you cannot use for inputs and outputs from PB.
Run the 3 line code in openconsole(), open the console on your Mac (programms/tools/console) and see the last line.
It is like it is! The console commands are not usable on Mac.
sorry that's not correct. Try to use the OpenConsole() command in a
source code and run it from the IDE (for an example and an explanation
take a look into this posting from me). When opening the console please
examine the window title. It displays "Terminal...". So "Console" and
"Terminal" seem to be used as synonyms on the Mac...

problem to use the PB console commands as long as you change
"Executable format" in "Compiler/Compiler Options..." from "MacOS" to
"Console" before compiling...