# Error running experiment on mac

**URL:** <https://psychtoolbox.discourse.group/t/error-running-experiment-on-mac/4093>\
**Category:** Programming Help\
**Tags:** macos\
**Created:** [November 2, 2021, 11:09am UTC](https://psychtoolbox.discourse.group/t/error-running-experiment-on-mac/4093 "2021-11-02T11:09:36Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![evioletb](https://avatars.discourse-cdn.com/v4/letter/e/e0b2c6/32.png) [@evioletb](https://psychtoolbox.discourse.group/u/evioletb)\
**Post date:** [November 2, 2021, 11:09am UTC](https://psychtoolbox.discourse.group/t/error-running-experiment-on-mac/4093/1 "2021-11-02T11:09:36Z")

</div>

Hi,

I am trying to run an experiment on my mac (not for the actual experimental presentation but to debug and that sort of thing) but I keep getting the following error:

```auto
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision unknown
PTB-INFO: Retina display. Enabling panel fitter for scaled Retina compatibility mode.

PTB-INFO: This is Psychtoolbox-3 for Apple macOS, under Matlab 64-Bit (Version 3.0.18 - Build date: Oct 23 2021).
PTB-INFO: OS support status: OSX version 11.0 is not yet tested or officially supported at all for this Psychtoolbox release.
PTB-INFO: Type 'PsychtoolboxVersion' for more detailed version information.
PTB-INFO: Most parts of the Psychtoolbox distribution are licensed to you under terms of the MIT License, with
PTB-INFO: some restrictions. See file 'License.txt' in the Psychtoolbox root folder for the exact licensing conditions.

PTB-INFO: For information about paid priority support, community membership and commercial services, please type
PTB-INFO: 'PsychPaidSupportAndServices'.

PTB-WARNING:PsychOSFixupFramebufferFormatForTiming: On screenId 0 no suitable mode with targetBpc 8. No-Op. Timing will suck!

PTB-ERROR[CGLSetFullScreenOnDisplay failed: invalid fullscreen drawable]. Main Screen() context

PTB-ERROR[Low-Level setup of window failed]:The specified gpu + display + gfx-driver combo may not support some requested feature.

Error using Screen
See error message printed above.

Error in untitled (line 26)
[window, rect]=Screen('OpenWindow',0);

```

This is the code I am trying to run:

```auto
% Clear the workspace and screen

sca;

close all;

clear all;

% Name keys

escapeKey = KbName('ESCAPE');

leftKey = KbName('LeftArrow');

rightKey = KbName('RightArrow');

downKey = KbName('DownArrow');

upKey = KbName('UpArrow');

% Get participant_information

participant_number = 'Enter subject number:';

prompt = {'Enter subject number:'};

answer = inputdlg(prompt, 'Subject Number',1.2,{'2'});

% Configure settings

PsychDefaultSetup(2);

InitializePsychSound(1);

screenNumber = max(Screen('Screens'));

black = BlackIndex(screenNumber);

white = WhiteIndex(screenNumber);

% Open black screen

[window, rect]=Screen('OpenWindow',0);

Screen('FrameRect',window,black,[200 200 400 400])

WaitSecs(2);

sca;

```

---

<div class="post-metadata">

**Author:** ![mariokleiner](https://avatars.discourse-cdn.com/v4/letter/m/13edae/32.png) [@mariokleiner](https://psychtoolbox.discourse.group/u/mariokleiner)\
**Post date:** [November 3, 2021, 6:38am UTC](https://psychtoolbox.discourse.group/t/error-running-experiment-on-mac/4093/2 "2021-11-03T06:38:51Z")

</div>

Is this a M1 Mac with Apple Silicone? What is the full output of `c = Screen('Computer')`, ie. the values of all fields in this struct and its sub-structs, e.g., `c.hw` and `c.kern` ? There’s a thread about M1 here:

> [@Using toolbox with Big Sur and M1 MacBook?](https://psychtoolbox.discourse.group/t/using-toolbox-with-big-sur-and-m1-macbook/3599/9):
>
> Just in case it’s at all useful. I just tried to run GarboriumDemo on my M1 MacBook Air in MATLAB R2019b with no joy: Will draw 200 gabor patches per frame. PTB-INFO: Retina display. Enabling panel fitter for scaled Retina compatibility mode. PTB-INFO: This is Psychtoolbox-3 for Apple OS X, under Matlab 64-Bit (Version 3.0.17 - Build date: Dec 17 2020). PTB-INFO: OS support status: OSX version 11.0 is not yet tested or officially supported at all for this Psychtoolbox release. PTB-INFO: Typ…

-mario
