Files
ueforth/esp32/autoboot.fs
Brad Nelson 9ef1ea9f90 Clean up include, autoboot, split windows, shorten start.
Drop startup timeout to 100ms.
Clean up exceptions in include.
Cleanup stack in autoboot.
Split out windows into a second string, to work around overflow issue.
2023-01-22 16:44:42 -08:00

36 lines
1.2 KiB
Forth

\ Copyright 2021 Bradley D. Nelson
\
\ Licensed under the Apache License, Version 2.0 (the "License");
\ you may not use this file except in compliance with the License.
\ You may obtain a copy of the License at
\
\ http://www.apache.org/licenses/LICENSE-2.0
\
\ Unless required by applicable law or agreed to in writing, software
\ distributed under the License is distributed on an "AS IS" BASIS,
\ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\ See the License for the specific language governing permissions and
\ limitations under the License.
internals definitions
( Change default block source on arduino )
: arduino-default-use s" /spiffs/blocks.fb" open-blocks ;
' arduino-default-use is default-use
( Setup remember file )
: arduino-remember-filename s" /spiffs/myforth" ;
' arduino-remember-filename is remember-filename
( Check for autoexec.fs and run if present.
Failing that, try to revive save image. )
: autoexec
( Allow skip start files if key hit within 100 ms )
10 for key? if rdrop exit then 10 ms next
s" /spiffs/autoexec.fs" 2dup file-exists?
if included else 2drop then
['] revive catch drop ;
' autoexec ( leave on the stack for fini.fs )
forth definitions