mail.coreboot.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
List overview
Download
openfirmware
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
openfirmware@openfirmware.info
3007 discussions
Start a n
N
ew thread
[commit] r3557 - cpu/arm/olpc/cl4 dev ofw/wifi
by repository service
18 Feb '13
18 Feb '13
Author: quozl Date: Mon Feb 18 08:31:19 2013 New Revision: 3557 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3557
Log: OLPC - libertas, add support for 802.11n 5 GHz networks on 8787. Due to a firmware limit of 14 channels in a scan request, the scan logic was heavily changed. During association a specific channel scan order is followed, and the first match stops further scanning. The LEDs test was also changed to reduce the time taken. #12552. Modified: cpu/arm/olpc/cl4/leds.fth dev/libertas.fth ofw/wifi/data.fth ofw/wifi/eapol.fth Modified: cpu/arm/olpc/cl4/leds.fth ============================================================================== --- cpu/arm/olpc/cl4/leds.fth Mon Feb 18 01:01:24 2013 (r3556) +++ cpu/arm/olpc/cl4/leds.fth Mon Feb 18 08:31:19 2013 (r3557) @@ -30,7 +30,7 @@ ols-led-on d# 100 ms hdd-led-on - " /wlan:quiet" test-dev + " led-blink" $call-wlan d# 100 ms ols-led-off ols-led-ec-control @@ -42,13 +42,16 @@ ; : (selftest) + 0 to wlan-ih + " /wlan:force" open-dev ?dup if to wlan-ih then get-msecs d# 10000 + ( limit ) begin (cycle) - key? if drop exit then + key? if drop wlan-ih close-dev exit then dup get-msecs - 0< ( limit timeout? ) until ( limit ) drop ( ) + wlan-ih close-dev ; : selftest ( -- error? ) Modified: dev/libertas.fth ============================================================================== --- dev/libertas.fth Mon Feb 18 01:01:24 2013 (r3556) +++ dev/libertas.fth Mon Feb 18 08:31:19 2013 (r3557) @@ -105,6 +105,8 @@ : ssid$ ( -- $ ) ssid /ssid ; 0 value channel +0 value 802.11n? \ Hardware is 802.11n capable +: channel-is-5ghz? ( chan# -- ) d# 14 > ; d# 80 buffer: wpa-ie \ WPA IE saved for EAPOL phases 0 value /wpa-ie @@ -707,6 +709,11 @@ : set-fw-params ( -- ) get-hw-spec 0= if ( adr ) + \ is 802.11n capable? + dup d# 34 + le-l@ h# 800 and if + true to 802.11n? + then ( adr ) + \ The 4-byte FWReleaseNumber field starts at offset d# 18. \ Firmware version 2.3.4.p1 is represented in that field \ as 04 03 02 01, i.e. the first three bytes are little-endian, @@ -1138,19 +1145,16 @@ h# 7ffe instance value channel-mask -: +chan-list-tlv ( -- ) +: +chan-tlv ( channel# -- ) h# 101 +xw - 0 +xw 'x >r ( r: 'payload ) - #channels 1+ 1 do - 1 i lshift channel-mask and if - 0 +xb \ Radio type - i +xb \ Channel # - scan-type +xb \ Scan type - 0:active or 1:passive - d# 100 +xw \ Min scan time - d# 100 +xw \ Max scan time - then - loop - 'x r@ - r> 2- le-w! + 0 +xw 'x >r ( channel# r: payload' ) + dup channel-is-5ghz? if 1 else 0 then ( channel# band# ) + +xb \ Band # + +xb \ Channel # + scan-type +xb \ Scan type - 0:active or 1:passive + d# 100 +xw \ Min scan time + d# 100 +xw \ Max scan time ( r: payload' ) + 'x r@ - r> 2- le-w! ( ) ; : +probes-tlv ( -- ) @@ -1167,19 +1171,32 @@ then ; -: (scan) ( -- error? | adr len 0 ) +: (scan) ( chan -- error? | adr len 0 ) + + \ forge success for 2.4 ghz channels disabled in the channel-mask + dup channel-is-5ghz? 0= if ( chan ) + 1 over lshift channel-mask and 0= if ( chan ) + drop respbuf 0 0 exit + then + then ( chan ) + + \ forge success for 5 ghz channels if the device lacks support + dup channel-is-5ghz? 802.11n? 0= and if + drop respbuf 0 0 exit + then + 6 ( CMD_802_11_SCAN ) start-cmd resp-wait-long to resp-wait BSS_ANY +xb 6 +xerase \ BSS ID - +chan-list-tlv + +chan-tlv +probes-tlv +ssid-tlv - finish-cmd outbuf-wait dup 0= if ( error? ) - respbuf /respbuf /fw-cmd /string rot ( adr len 0 ) + finish-cmd outbuf-wait dup 0= if ( error? ) + respbuf /respbuf /fw-cmd /string rot ( adr len 0 ) then ; @@ -1200,14 +1217,21 @@ d# 32 min scan-ssid pack drop ; -: scan ( adr len -- actual ) -\ (scan) - begin (scan) dup 1 = while drop d# 1000 ms repeat \ Retry while busy - if 2drop 0 exit then ( adr len scan-adr scan-len ) - rot min >r ( adr scan-adr r: len ) - swap r@ move ( r: len ) - r> +: scan ( adr len chan -- actual ) + dup channel-is-5ghz? 802.11n? 0= and if 3drop 0 exit then + >r ( adr len r: chan ) + begin + r@ (scan) dup 1 = + while + drop d# 1000 ms \ retry while busy + repeat ( adr len scan-adr scan-len err? r: chan ) + r> drop ( adr len scan-adr scan-len err? ) + if 2drop 0 exit then ( adr len scan-adr scan-len ) + rot min >r ( adr scan-adr r: actual ) + swap r@ move ( r: actual ) + r> ( actual ) ; + headers \ ========================================================================= @@ -1550,7 +1574,7 @@ \ DS param 3 +xw \ element ID = DS param set 1 +xw \ len - ( ch ) +xb \ channel + dup +xb \ channel \ CF param 4 +xw \ element ID = CF param set @@ -1599,6 +1623,9 @@ /x save-wpa-ie \ Save IE in wpa-ie then + \ associating with a 5 GHz channel requires the band to be specified + 802.11n? if +chan-tlv else drop then ( ) + \ XXX power (optional) \ XXX supported channels set (802.11h only) \ XXX pass thru IEs (optional) @@ -2327,57 +2354,21 @@ " target-mac$" $call-supplicant disassociate ; -\ adr len is the result of (scan) - a list of APs and their characteristics -: test-association ( adr len -- error? ) - " OLPCOFW" " select-ssid?" $call-supplicant if ( ) - " (do-associate)" $call-supplicant if ( ) - \ Success - do-disassociate - " true to ssid-reset?" ['] evaluate catch if 2drop then - false - else - true - then - else - \ There is no OLPCOFW access point, so we don't try associating - false - then -; - : (scan-wifi) ( -- error? ) true to force-open? open false to force-open? 0= if ." Can't open Marvell wireless" cr true close exit then - - (scan) if - ." Failed to scan" true cr - else ( adr len ) -\ drop .scan false - diagnostic-mode? if ( adr len ) - drop 2+ c@ if ( ) - false - else - ." ERROR: No access points seen" cr - true - then - else ( adr len ) - \ Quiet mode is for the benefit of the LEDs test, so we can flash - \ the WLAN LEDS without distracting messages appearing on the screen - quiet? if ( adr len ) - 2drop false ( error? ) - else - 2dup .ssids ( adr len ) - test-association ( error? ) - then ( error? ) - then - then - + " scan-all" $call-supplicant ( error? ) close ; : scan-wifi ( -- ) (scan-wifi) drop ; +: led-blink ( -- ) + d# 6 (scan) 0= if 2drop then +; + : reassociate ( -- ) do-disassociate do-associate if ." succeeded" else ." failed" then cr @@ -2454,8 +2445,7 @@ : ta-scan ( -- ) ." scan" cr - (scan) ( adr len error? ) - 0= if .ssids cr then ( ) + (scan-all) drop ; : ta-n ( n -- ) Modified: ofw/wifi/data.fth ============================================================================== --- ofw/wifi/data.fth Mon Feb 18 01:01:24 2013 (r3556) +++ ofw/wifi/data.fth Mon Feb 18 08:31:19 2013 (r3557) @@ -8,7 +8,7 @@ : wpa-ie$ ( -- adr len ) " wpa-ie$" $call-parent ; : write-force ( adr len -- actual ) " write-force" $call-parent ; : read-force ( adr len -- actual ) " read-force" $call-parent ; -: scan ( adr len -- actual ) " scan" $call-parent ; +: scan ( adr len chan -- actual ) " scan" $call-parent ; : enable-rsn ( -- ) " enable-rsn" $call-parent drop ; : disable-rsn ( -- ) " disable-rsn" $call-parent drop ; : disable-wep ( -- ) " disable-wep" $call-parent drop ; Modified: ofw/wifi/eapol.fth ============================================================================== --- ofw/wifi/eapol.fth Mon Feb 18 01:01:24 2013 (r3556) +++ ofw/wifi/eapol.fth Mon Feb 18 08:31:19 2013 (r3557) @@ -922,19 +922,62 @@ ssid$ (select-ssid?) ( found? ) ; +create scan-order + d# 6 c, d# 1 c, d# 11 c, + + d# 2 c, d# 3 c, d# 4 c, d# 5 c, d# 7 c, d# 8 c, + d# 9 c, d# 10 c, d# 12 c, d# 13 c, d# 14 c, + + d# 36 c, d# 40 c, d# 44 c, d# 48 c, + d# 52 c, d# 56 c, d# 60 c, d# 64 c, + + d# 100 c, d# 104 c, d# 108 c, + d# 112 c, d# 116 c, d# 132 c, d# 136 c, + + d# 140 c, d# 149 c, d# 153 c, + d# 157 c, d# 161 c, d# 165 c, +here scan-order - constant /scan-order + +: test-association ( adr len -- error? ) + " OLPCOFW" select-ssid? if + (do-associate) if + target-mac$ " disassociate" $call-parent + true to ssid-reset? + then + then +; + +: scan-all ( -- error? ) + scan-order /scan-order bounds do ( ) + scanbuf /buf i c@ ( adr len chan ) + scan dup if ( actual ) + scanbuf swap ( adr len ) + 2dup .ssids ( adr len ) + test-association + else ( actual ) + drop unloop true exit + then + loop + false +; + : scan-ssid? ( ssid$ -- found? ) dup 0= if 2drop false exit then ( ssid$ ) ssid! ( ) ssid$ " set-ssid" $call-parent ( ) ??cr ." Scan for: " ssid$ type space ( ) - scanbuf /buf scan if ( ) - debug? if scanbuf .scan then ( ) - ssid$ (select-ssid?) ( found? ) - dup if ." found" else ." failed" then cr - else ( ) - ." not found" cr false ( found? ) - then ( found? ) + + scan-order /scan-order bounds do ( ) + scanbuf /buf i c@ ( adr len chan ) + scan if ( ) + debug? if scanbuf .scan then ( ) + ssid$ (select-ssid?) ( found? ) + if ." found" cr unloop true exit then + then + loop + ." not found" cr false ( found? ) ; + : try-scan ( -- okay? ) wifi-ssid$ scan-ssid? if true exit then default-ssids begin dup while ( rem$ )
1
0
0
0
[commit] r3556 - cpu/arm/olpc
by repository service
18 Feb '13
18 Feb '13
Author: quozl Date: Mon Feb 18 01:01:24 2013 New Revision: 3556 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3556
Log: OLPC XO-4 - touchscreen, restore missing test instructions during scribble and axes tests, fixes a regression introduced in r3535. #12553. Modified: cpu/arm/olpc/nn-touchscreen.fth Modified: cpu/arm/olpc/nn-touchscreen.fth ============================================================================== --- cpu/arm/olpc/nn-touchscreen.fth Thu Feb 14 06:01:19 2013 (r3555) +++ cpu/arm/olpc/nn-touchscreen.fth Mon Feb 18 01:01:24 2013 (r3556) @@ -906,6 +906,7 @@ consume flush blacken + .tsmsg -1 to remaining ;
1
0
0
0
[commit] r3555 - cpu/x86/pc/olpc
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 06:01:19 2013 New Revision: 3555 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3555
Log: OLPC - startup sound. Avoid searching jffs2 filesystem on XO-1 because mounting it takes a long time. Avoid checking for file existence; just try and if we fail, fallback to the built-in sound. Avoids one microSD or eMMC power cycle from boot on XO-1.5, XO-1.75, and XO-4 when the startup sound is present. Modified: cpu/x86/pc/olpc/sound.fth Modified: cpu/x86/pc/olpc/sound.fth ============================================================================== --- cpu/x86/pc/olpc/sound.fth Thu Feb 14 05:37:52 2013 (r3554) +++ cpu/x86/pc/olpc/sound.fth Thu Feb 14 06:01:19 2013 (r3555) @@ -28,13 +28,20 @@ : softer ( -- ) -2 +volume ; : louder ( -- ) 2 +volume ; -" int:\boot\jingle.wav" d# 128 config-string jingle -: sound-name$ ( -- adr len ) - jingle $file-exists? if - jingle - else - " rom:splash" - then +: sound-int? ( -- error? ) + " int:\boot\jingle.wav" ['] $play-wav catch dup if nip nip then +; + +: sound-rom? ( -- error? ) + " rom:splash" ['] $play-wav catch dup if nip nip then +; + +: (sound) + [ifdef] jffs2-support + sound-rom? drop \ jffs2 is very slow to mount + [else] + sound-int? if sound-rom? drop then + [then] ; : sound ( -- ) @@ -42,7 +49,7 @@ playback-volume >r get-saved-volume to playback-volume ['] load-started behavior >r ['] noop to load-started - sound-name$ ['] $play-wav catch if 2drop then + (sound) r> to load-started r> to playback-volume ;
1
0
0
0
[commit] r3554 - cpu/x86/pc/olpc
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 05:37:52 2013 New Revision: 3554 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3554
Log: OLPC XO-1 - suppress DCON switching during display test, to fix regression due to earlier reorganisation Modified: cpu/x86/pc/olpc/disptest.fth Modified: cpu/x86/pc/olpc/disptest.fth ============================================================================== --- cpu/x86/pc/olpc/disptest.fth Thu Feb 14 05:33:10 2013 (r3553) +++ cpu/x86/pc/olpc/disptest.fth Thu Feb 14 05:37:52 2013 (r3554) @@ -173,9 +173,9 @@ ; : wait ( -- ) hold-time - dcon-screen-freeze + [ifdef] dcon-screen-freeze dcon-screen-freeze [then] hold-time - dcon-screen-unfreeze + [ifdef] dcon-screen-unfreeze dcon-screen-unfreeze [then] hold-time2 ;
1
0
0
0
[commit] r3553 - cpu/x86/pc/olpc
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 05:33:10 2013 New Revision: 3553 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3553
Log: Q2F15 Modified: cpu/x86/pc/olpc/versions.fth Modified: cpu/x86/pc/olpc/versions.fth ============================================================================== --- cpu/x86/pc/olpc/versions.fth Thu Feb 14 05:02:38 2013 (r3552) +++ cpu/x86/pc/olpc/versions.fth Thu Feb 14 05:33:10 2013 (r3553) @@ -2,7 +2,7 @@ \ The overall firmware revision macro: FW_MAJOR F -macro: FW_MINOR 14 +macro: FW_MINOR 15 \ Create a 2-character build/fw-suffix file to personalize your test builds " fw-suffix" $file-exists? [if]
1
0
0
0
[commit] r3552 - dev/olpc
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 05:02:38 2013 New Revision: 3552 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3552
Log: OLPC XO-1.5 - lid test needed factory-test? defined Modified: dev/olpc/lidtest.fth Modified: dev/olpc/lidtest.fth ============================================================================== --- dev/olpc/lidtest.fth Thu Feb 14 04:59:05 2013 (r3551) +++ dev/olpc/lidtest.fth Thu Feb 14 05:02:38 2013 (r3552) @@ -45,6 +45,10 @@ pltd wait-not-ebook ty ; +[ifndef] factory-test? +: factory-test? false ; +[then] + : selftest ( -- error? ) factory-test? if ['] all-switch-states catch
1
0
0
0
[commit] r3551 - cpu/x86/pc/olpc/via
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 04:59:05 2013 New Revision: 3551 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3551
Log: Q3C11 Modified: cpu/x86/pc/olpc/via/fw-version.fth Modified: cpu/x86/pc/olpc/via/fw-version.fth ============================================================================== --- cpu/x86/pc/olpc/via/fw-version.fth Thu Feb 14 04:39:22 2013 (r3550) +++ cpu/x86/pc/olpc/via/fw-version.fth Thu Feb 14 04:59:05 2013 (r3551) @@ -1,6 +1,6 @@ \ The overall firmware revision macro: FW_MAJOR C -macro: FW_MINOR 10 +macro: FW_MINOR 11 \ Create a 2-character build/fw-suffix file to personalize your test builds " fw-suffix" $file-exists? [if]
1
0
0
0
[commit] r3550 - cpu/arm/olpc/1.75
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 04:39:22 2013 New Revision: 3550 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3550
Log: Q4D27 Modified: cpu/arm/olpc/1.75/fw-version.fth Modified: cpu/arm/olpc/1.75/fw-version.fth ============================================================================== --- cpu/arm/olpc/1.75/fw-version.fth Thu Feb 14 03:57:04 2013 (r3549) +++ cpu/arm/olpc/1.75/fw-version.fth Thu Feb 14 04:39:22 2013 (r3550) @@ -1,7 +1,7 @@ \ The overall firmware revision macro: FW_PREFIX Q4 macro: FW_MAJOR D -macro: FW_MINOR 26 +macro: FW_MINOR 27 \ Create a 2-character build/fw-suffix file to personalize your test builds " fw-suffix" $file-exists? [if]
1
0
0
0
[commit] r3549 - cpu/arm/olpc/4.0
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 03:57:04 2013 New Revision: 3549 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3549
Log: Q7B16 Modified: cpu/arm/olpc/4.0/fw-version.fth Modified: cpu/arm/olpc/4.0/fw-version.fth ============================================================================== --- cpu/arm/olpc/4.0/fw-version.fth Thu Feb 14 03:26:44 2013 (r3548) +++ cpu/arm/olpc/4.0/fw-version.fth Thu Feb 14 03:57:04 2013 (r3549) @@ -1,7 +1,7 @@ \ The overall firmware revision macro: FW_PREFIX Q7 macro: FW_MAJOR B -macro: FW_MINOR 15 +macro: FW_MINOR 16 \ Create a 2-character build/fw-suffix file to personalize your test builds " fw-suffix" $file-exists? [if]
1
0
0
0
[commit] r3548 - dev/olpc
by repository service
14 Feb '13
14 Feb '13
Author: quozl Date: Thu Feb 14 03:26:44 2013 New Revision: 3548 URL:
http://tracker.coreboot.org/trac/openfirmware/changeset/3548
Log: OLPC - rewrite switch tests for field only, #12514 Modified: dev/olpc/lidtest.fth Modified: dev/olpc/lidtest.fth ============================================================================== --- dev/olpc/lidtest.fth Thu Feb 14 02:41:12 2013 (r3547) +++ dev/olpc/lidtest.fth Thu Feb 14 03:26:44 2013 (r3548) @@ -3,31 +3,54 @@ : open ( -- okay? ) true ; : close ( -- ) ; + : ?key-abort ( -- ) key? if key esc = abort" Aborted" then ; -: wait-not-lid ( -- ) - ." Deactivate lid switch" cr - begin ?key-abort lid? 0= until -; -: wait-lid ( -- ) - ." Activate lid switch" cr - begin ?key-abort lid? until -; -: wait-not-ebook ( -- ) - ." Deactivate ebook switch" cr - begin ?key-abort ebook? 0= until -; -: wait-ebook ( -- ) - ." Activate ebook switch" cr - begin ?key-abort ebook? until -; + +: wait-not-lid ( -- ) begin ?key-abort lid? 0= until ; +: wait-lid ( -- ) begin ?key-abort lid? until ; +: wait-not-ebook ( -- ) begin ?key-abort ebook? 0= until ; +: wait-ebook ( -- ) begin ?key-abort ebook? until ; : all-switch-states ( -- ) - lid? if wait-not-lid else wait-lid then - ebook? if wait-not-ebook else wait-ebook then + lid? if + ." Deactivate lid switch" cr + wait-not-lid + else + ." Activate lid switch" cr + wait-lid + then + ebook? if + ." Deactivate ebook switch" cr + wait-not-ebook + else + ." Activate ebook switch" cr + wait-ebook + then +; + +: ty ." Thank you." cr cr ; +: pltd ." Please lift the display and rotate it to face you." cr ; + +: field-switch-states ( -- ) + cr + ebook? if pltd wait-not-ebook ty then + + lid? if ." Please open the lid." cr wait-not-lid ty then + + ." Please close the lid and then open it." cr + wait-lid d# 1000 ms wait-not-lid ty + + ." Please rotate the lid to face away, and close it face up." cr + wait-ebook d# 1000 ms ty + pltd wait-not-ebook ty ; : selftest ( -- error? ) - ['] all-switch-states catch + factory-test? if + ['] all-switch-states catch + else + ['] field-switch-states catch + then ; \ LICENSE_BEGIN
1
0
0
0
← Newer
1
...
23
24
25
26
27
28
29
...
301
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
Results per page:
10
25
50
100
200