File tree Expand file tree Collapse file tree 14 files changed +69
-53
lines changed
Expand file tree Collapse file tree 14 files changed +69
-53
lines changed Original file line number Diff line number Diff line change 22# Script_name : bert_ev3dev_functions
33# Author : Bert Lindeman
44# Description : functions that can be used by more than one bash script related to ev3dev
5- # Version : v1.1
6- # Date : 2014-09-08
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : . /usr/local/bin/bert_ev3dev_functions
88# Notes :
99# Copyright : 2014 Bert Lindeman
1313#
1414# Changelog
1515# Date By Description
16+ # 20141104 BL prepare for release v1.3
1617# 20141020 BL Added reverse colors
1718#
1819# ============================================================================
Original file line number Diff line number Diff line change 22# Script_name : blinkleds
33# Author : Bert Lindeman
44# Description : Have the EV3-leds blink red amber and green
5- # Version : v1.2
6- # Date : 2014-08-26
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : blinkleds
88# Notes : No parameters used
99# Copyright : 2014 Bert Lindeman
1313#
1414# Changelog
1515# Date By Description
16- # 20140826 BL o Added script header
17- # o Show in the terminal what is being done.
16+ # 20141104 BL prepare for release v1.3
1817# 20140906 BL o Wait a little linger at each step
1918# Update to kernel 3.16.1 made things FASTER
2019# o Set brightness to more than 1 as this NOW works.
2120# use to make sliding colors
21+ # 20140826 BL o Added script header
22+ # o Show in the terminal what is being done.
2223# ============================================================================
2324#
2425. /usr/local/bin/bert_ev3dev_functions
Original file line number Diff line number Diff line change 22# Script_name : blinkvoltage
33# Author : Bert Lindeman
44# Description : Set the left EV3-led according to the battery voltage
5- # Version : v1.1
6- # Date : 2014-08-26
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : blinkvoltage [color]
88# Notes : o color is [ none | red | green | amber ]
99# o very good to add this script to a crontab
1515#
1616# Changelog
1717# Date By Description
18+ # 20141104 BL prepare for release v1.3
19+ # 20140914 BL Also use the actual voltage to set the blinkling
1820# 20140826 BL o Add script header
1921# o try to prevent abmber blinking flipflop red/green
20- # 20140914 BL Also use the actual voltage to set the blinkling
2122# ============================================================================
2223
2324
Original file line number Diff line number Diff line change 44# Description : Check the battery voltage and warn if the voltage is
55# less than 7 volts,
66# also set the left EV3 led to blinking green, amber or red.
7- # Version : v1.2
8- # Date : 2014-08-26
7+ # Version : v1.3
8+ # Date : 2014-11-04
99# Usage : checkpower
1010# No arguments needed nor used
1111# Notes : ! TOBE verified: At what voltage does the brick shutdown.
2020#
2121# Changelog :
2222# Date By Description
23- # 20140826 BL o Add header
24- # o Do not ALWAYS state that power is "OK"
25- # but show the status WARN / MED / LOW / OK
26- # o whole algorithm did NOT work :-(
27- # o Check if ENVIRONMENT variable is set.
23+ # 20141104 BL prepare for release v1.3
2824# 20140827 BL o 6 volts is just a bit too low as last warning level
2925# Last drop of voltage e.g. was too much
3026# from 6303066 to 5668733 in 10 minutes (my check interval)
3329# 20140914 BL o add the voltage to the blinkvoltage call,
3430# to adapt the type of blinking.
3531# Since kernel 3.16.1 leds can be controlled better.
32+ # 20140826 BL o Add header
33+ # o Do not ALWAYS state that power is "OK"
34+ # but show the status WARN / MED / LOW / OK
35+ # o whole algorithm did NOT work :-(
36+ # o Check if ENVIRONMENT variable is set.
3637# ============================================================================
3738
3839
Original file line number Diff line number Diff line change 33# Author : Bert Lindeman
44# Description : List sensors and motors
55# Version : v1.3
6- # Date : 2014-09-28
6+ # Date : 2014-11-04
77# Usage : listports
88# Notes :
99# Copyright : 2014 Bert Lindeman
1010# License : GPL-3.0+
1111#
12+ # ============================================================================
1213#
1314#
1415# Changelog
1516# Date By Description
17+ # 20141104 BL o prepare for release v1.3
18+ # o Take terminal-width into account
19+ # 20141020 BL o adapt to motor mappings (kernel 3.16.1-6)
20+ # o add rcx leds and motors
1621# 20140928 BL o Adapt to updates in
1722# kernel version 3.16.1-3-ev3dev
1823# and 3.16.1-4-ev3dev
1924# o remove field type_id
2025# o slightly different file names
2126# o motor type -> device_type
2227# o issue 123: force mode to input ports and output ports
23- # 20141020 BL o adapt to motor mappings (kernel 3.16.1-6)
24- # o add rcx leds and motors
25- # 20141104 BL Take terminal-width into account
28+ #
29+ # ============================================================================
2630
2731. /usr/local/bin/bert_ev3dev_functions
2832
Original file line number Diff line number Diff line change 22# Script_name : setled
33# Author : Bert Lindeman
44# Description : Set an EV3-led
5- # Version : v1.2
6- # Date : 2014-08-26
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : setled
88# Notes : 4 optional parameters:
99# color [side [ON | OFF [valid MODE]]]
1414#
1515# Changelog
1616# Date By Description
17- # 20140826 BL add script header
17+ # 20141104 BL prepare for release v1.3
1818# 20140910 BL Set ON to a higher value than 1
1919# brightness since kernel 3.16.1 is honoured
2020# and no longer a switch
21+ # 20140826 BL add script header
2122#
2223# ============================================================================
2324
Original file line number Diff line number Diff line change 22# Script_name : showactivity
33# Author : Bert Lindeman
44# Description : Let the rightside green EV3-led blink depending on I/O activiy
5- # Version : v1.1
6- # Date : 2014-08-26
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : showactivity
88# Notes : No parameters used nor checked
99# Copyright : 2014 Bert Lindeman
1313#
1414# Changelog
1515# Date By Description
16+ # 20141104 BL prepare for release v1.3
1617# 20140826 BL o Add script header
1718# o No longer show triggers of the leds (confusing)
1819#
Original file line number Diff line number Diff line change 22# Script_name : showleds
33# Author : Bert Lindeman
44# Description : Show values of EV3-leds
5- # Version : v1.2
6- # Date : 2014-08-26
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : showleds
88# Notes : No arguments needed nor used
99# o brightness is only non-zero at the time
1616#
1717# Changelog :
1818# Date By Description
19+ # 20141104 BL prepare for release v1.3
20+ # 20141023 BL o Since 3.16.1-6 also PF-leds possible
21+ # o move show[LED]trigger to ev3dev_functions
22+ # 20140914 BL Color for some values
1923# 20140826 BL o Show delay_on and delay_off if available for
2024# this led and for it's trigger
2125# o adapt usage clause (no parameters)
22- # 20140914 BL Color for some values
23- # 20141023 BL o Since 3.16.1-6 also PF-leds possible
24- # o move show[LED]trigger to ev3dev_functions
26+ #
2527# ============================================================================
26-
27-
2828#
2929
3030. /usr/local/bin/bert_ev3dev_functions
Original file line number Diff line number Diff line change 22# Script_name : showmotor
33# Author : Bert Lindeman
44# Description : Show status of connected motors
5- # Version : v1.2
6- # Date : 2014-08-26
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : showmotor
88# Notes : Only tested with LEGO EV3 and NXT motors
99# Copyright : 2014 Bert Lindeman
1313#
1414# Changelog
1515# Date By Description
16- # 20140826 BL Add script header
17- # 20140911 BL adapt to changes at kernel 3.16.1-2
16+ # 20141104 BL prepare for release v1.3
1817# 20141023 BL adapt to changes at kernel 3.16.1-6
18+ # 20140911 BL adapt to changes at kernel 3.16.1-2
19+ # 20140826 BL Add script header
1920# ============================================================================
2021#
2122#
Original file line number Diff line number Diff line change 22# Script_name : showpower
33# Author : Bert Lindeman
44# Description : Show variables related to EV3 battery
5- # Version : v1.2
6- # Date : 2014-08-26
5+ # Version : v1.3
6+ # Date : 2014-11-04
77# Usage : showpower
88# Notes : The field "status" has a fixed value "Discharging"
99# this is by kernel design.
1414#
1515# Changelog
1616# Date By Description
17+ # 20141104 BL prepare for release v1.3
18+ # 20140914 BL small cleanup
1719# 20140826 BL 0 add script header
1820# 0 made a bit more robust
19- # 20140914 BL small cleanup
2021# ============================================================================
2122
2223devide_1000000 () {
You can’t perform that action at this time.
0 commit comments