The answer is just as low-level as
POKE, but is not
OUT 255,2 enters "Hi-Color" mode
OUT 255,6* enters "Hi-Res" mode
OUT 255,0 goes back to normal Spectrum mode
OUT is similar to
POKE but writes to an I/O port rather than a RAM address. Port 255 also controls other things by setting other bits. Note that
2 above sets bit 1 and
6 sets bits 2 and 4. *Some sources state that Hi-Res requires
I don't think BASIC supports the non-Speccy modes in display, not just not by having commands to change modes. This means that if you change the mode in BASIC you will see garbage, and not your program displaying in 64 modes or with 1x8 colour attributes. You can still type blindly though.
Note that I haven't been able to test this fully since sources contradict each other and the TS 2068 emulated in MAME keeps crashing when I try to play with POKEing data into onto the screen. So there's probably mistakes in what Ive written. I will update this answer as I experiment...
It turns out it was crashing because the displayed memory in these modes actually overlaps the memory used by BASIC from what I can tell. So it really is only viable to use them in machine code.
Timex BASIC 64
So when you boot up a TS2068, even though it has a different ROM to a Sinclair ZX Spectrum, it's not all that different and has mostly the standard Sinclair BASIC with no support for the extra screen modes though it does have support for some of the other Timex features.
But there was also a version of BASIC made especially for the machine called "Timex BASIC 64". I expected it would come on a ROM cartridge "dock" to allow use of as much RAM to the programmer as possible and not require slow load from tape cassette after every crash. But from what I can find online, it was only available on tape. It did come in several versions for 2048 as well as 2068 and with and with floppy disk support.
This version of BASIC is designed to work in the TS-2068 memory map so your program and system variables etc will not exist in memory that is display memory for the extended graphics modes. Plus it includes extra commands including some to control the display mode:
n=0 screen resolution = 256x192
n=1 Screen resolution = 512x192
This is the same
SCREEN$ command that already has two functions in normal Speccy BASIC. It is used to read the character at a given screen x/y position; and it is used with
SAVE to read and write screen dump files to tape.
Note that this only allows you to select between normal and HiRes modes, but not HiColor mode, unless some info is missing.