rvido / imanager Goto Github PK
View Code? Open in Web Editor NEWAdvantech iManager Linux driver set for Advantech Embedded Boards
License: GNU General Public License v2.0
Advantech iManager Linux driver set for Advantech Embedded Boards
License: GNU General Public License v2.0
I've recently tried to update the iManager driver for my Linux variant and I noticed that the statistics that imanager-hwmon
module populates do not show any updates until after five (5) minutes of uptime. Before the update, an invoke of the sensors
command would display updated information for the "imanager_hwmon-isa-0000" block right away:
imanager_hwmon-isa-0000
Adapter: ISA adapter
+12V: +11.79 V (min = +0.00 V, max = +0.00 V) ALARM
+5V: +0.23 V (min = +0.00 V, max = +0.00 V) ALARM
VBat: +2.92 V (min = +0.00 V, max = +0.00 V) ALARM
FAN CPU: 0 RPM (min = 2000 RPM, max = 6000 RPM)
FAN SYS1: 1665 RPM (min = 2000 RPM, max = 6000 RPM)
Temp CPU: +40.0 C (low = +40.0 C, high = +85.0 C)
Temp SYS1: +40.0 C (low = +40.0 C, high = +85.0 C)
After updating to a newer version, the sensors information shows the following:
imanager_hwmon-isa-0000
Adapter: ISA adapter
+12VS0: +0.00 V (min = +0.00 V, max = +0.00 V)
+5VS0: +0.00 V (min = +0.00 V, max = +0.00 V)
+3.3VS0: +0.00 V (min = +0.00 V, max = +0.00 V)
FAN CPU: 0 RPM (min = 2000 RPM, max = 6000 RPM)
FAN SYS1: 2000 RPM (min = 2000 RPM, max = 6000 RPM)
Temp CPU: +63.0 C (low = +40.0 C, high = +85.0 C)
Temp SYS1: +63.0 C (low = +40.0 C, high = +85.0 C)
No voltages, RPMs or temperature values are updated until (almost exactly) five (5) minutes of uptime:
imanager_hwmon-isa-0000
Adapter: ISA adapter
+12VS0: +11.79 V (min = +0.00 V, max = +0.00 V) ALARM
+5VS0: +0.23 V (min = +0.00 V, max = +0.00 V) ALARM
+3.3VS0: +2.92 V (min = +0.00 V, max = +0.00 V) ALARM
FAN CPU: 0 RPM (min = 2000 RPM, max = 6000 RPM)
FAN SYS1: 1665 RPM (min = 2000 RPM, max = 6000 RPM)
Temp CPU: +39.0 C (low = +40.0 C, high = +85.0 C)
Temp SYS1: +39.0 C (low = +40.0 C, high = +85.0 C)
Explicit version/commit information:
imanager-core
, imanager-bl
and imanager-hwmon
root@leed3:/home/leed/iManager-master/iManager-master# make -C /lib/modules/uname -r
/build M=$PWD modules_install
make: Entering directory /usr/src/linux-headers-3.13.0-35-generic' INSTALL /home/leed/iManager-master/iManager-master/gpio-imanager.ko Can't read private key INSTALL /home/leed/iManager-master/iManager-master/i2c-imanager.ko Can't read private key INSTALL /home/leed/iManager-master/iManager-master/imanager.ko Can't read private key INSTALL /home/leed/iManager-master/iManager-master/imanager_bl.ko Can't read private key INSTALL /home/leed/iManager-master/iManager-master/imanager_hwmon.ko Can't read private key INSTALL /home/leed/iManager-master/iManager-master/imanager_wdt.ko Can't read private key DEPMOD 3.13.0-35-generic make: Leaving directory
/usr/src/linux-headers-3.13.0-35-generic'
The following is a suggestion towards marking the RELEASE
file version entry for specific release cycle events. If the following doesn't fit in your own release cycle process or is just not really desired, feel free to ignore this request.
The following suggests that the interim release value found in RELEASE
should be appended with a -git
postfix (ex. v1.4.0-git
). This would allow a developer to easily confirm the non-stable variant release from just using the source. Doing this, however, requires an official release to involve two (2) commits: a release commit (removing -git
postfix and tagging) and a kickoff cycle commit (updating new version target and re-adding postfix). Consider the following examples: release commit and kickoff cycle commit.
I have successfully built and used the GPIO driver. I noticed that the inputs do not have an edge
file in /sys/class/gpio/gpioXXX/
. Based on that, I'm assuming that the GPIOs do not support interrupts. Is that a function of the hardware or the kernel driver in gpio-imanager?
I've got an IT8528 chip or at least so does it seem, it's a Razer Blade 14' 2014 system and the IT87 module reports an unknown chip 0x8520 revision a.
However upon building, installing and loading the module I get:
insmod: ERROR: could not insert module imanager-core.ko: No such device
This is on Gentoo, under 4.7.2-gentooSources.
Am I doing something wrong?
I'm fairly new to the linux/embedded space but need to implement the watchdog for our SOM. So far I have successfully compiled and installed the module and am able to use the watchdog, but want to know if I am using the correct commands as the driver was intended. I will need to implement this using C#, and plan to run these commands using a C# Process object. Is there a better way to use the watchdog functionality?
To enable and feed the watchdog from the terminal, I am using:
echo 1 > /dev/watchdog1
To stop the watchdog, I use:
echo 0 > /dev/watchdog1
To change the timeout from the default, I use:
rmmod imanager_wdt
insmod /lib/modules/$(uname -r)/extra/imanager/imanager_wdt.ko timeout=60
This seems to work just fine, but I wanted to know if these commands are the correct usage or if there is a better way.
Thanks in advance
I am working on an Advantech MIO-5271 with Ubuntu 16.04 and kernel 4.4.0-31. After building and installing the kernel modules as described in the README, I am unable to export the GPIOs. My steps are below. Any help would be greatly appreciated. Thanks!
root@tm-test:~/iManager# make
make -C /lib/modules/4.4.0-31-generic/build M=/root/iManager clean
make[1]: Entering directory '/usr/src/linux-headers-4.4.0-31-generic'
make[1]: Leaving directory '/usr/src/linux-headers-4.4.0-31-generic'
rm -f -rf *.bak
make -C /lib/modules/4.4.0-31-generic/build M=/root/iManager modules
make[1]: Entering directory '/usr/src/linux-headers-4.4.0-31-generic'
CC [M] /root/iManager/imanager-core.o
CC [M] /root/iManager/gpio-imanager.o
CC [M] /root/iManager/i2c-imanager.o
CC [M] /root/iManager/imanager-hwmon.o
CC [M] /root/iManager/imanager_bl.o
CC [M] /root/iManager/imanager_wdt.o
Building modules, stage 2.
MODPOST 6 modules
CC /root/iManager/gpio-imanager.mod.o
LD [M] /root/iManager/gpio-imanager.ko
CC /root/iManager/i2c-imanager.mod.o
LD [M] /root/iManager/i2c-imanager.ko
CC /root/iManager/imanager-core.mod.o
LD [M] /root/iManager/imanager-core.ko
CC /root/iManager/imanager-hwmon.mod.o
LD [M] /root/iManager/imanager-hwmon.ko
CC /root/iManager/imanager_bl.mod.o
LD [M] /root/iManager/imanager_bl.ko
CC /root/iManager/imanager_wdt.mod.o
LD [M] /root/iManager/imanager_wdt.ko
make[1]: Leaving directory '/usr/src/linux-headers-4.4.0-31-generic'
root@tm-test:~/iManager# make install
make -C /lib/modules/4.4.0-31-generic/build M=/root/iManager modules
make[1]: Entering directory '/usr/src/linux-headers-4.4.0-31-generic'
Building modules, stage 2.
MODPOST 6 modules
make[1]: Leaving directory '/usr/src/linux-headers-4.4.0-31-generic'
make -C /lib/modules/4.4.0-31-generic/build M=/root/iManager INSTALL_MOD_DIR=extra/imanager modules_install
make[1]: Entering directory '/usr/src/linux-headers-4.4.0-31-generic'
INSTALL /root/iManager/gpio-imanager.ko
At main.c:222:
- SSL error:02001002:system library:fopen:No such file or directory: bss_file.c:175
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:178
sign-file: certs/signing_key.pem: No such file or directory
INSTALL /root/iManager/i2c-imanager.ko
At main.c:222:
- SSL error:02001002:system library:fopen:No such file or directory: bss_file.c:175
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:178
sign-file: certs/signing_key.pem: No such file or directory
INSTALL /root/iManager/imanager-core.ko
At main.c:222:
- SSL error:02001002:system library:fopen:No such file or directory: bss_file.c:175
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:178
sign-file: certs/signing_key.pem: No such file or directory
INSTALL /root/iManager/imanager-hwmon.ko
At main.c:222:
- SSL error:02001002:system library:fopen:No such file or directory: bss_file.c:175
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:178
sign-file: certs/signing_key.pem: No such file or directory
INSTALL /root/iManager/imanager_bl.ko
At main.c:222:
- SSL error:02001002:system library:fopen:No such file or directory: bss_file.c:175
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:178
sign-file: certs/signing_key.pem: No such file or directory
INSTALL /root/iManager/imanager_wdt.ko
At main.c:222:
- SSL error:02001002:system library:fopen:No such file or directory: bss_file.c:175
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:178
sign-file: certs/signing_key.pem: No such file or directory
DEPMOD 4.4.0-31-generic
make[1]: Leaving directory '/usr/src/linux-headers-4.4.0-31-generic'
/sbin/depmod -a
root@tm-test:~/iManager# modprobe imanager-core
root@tm-test:~/iManager# lsmod | grep imanager
imanager_wdt 16384 0
i2c_imanager 16384 0
imanager_hwmon 28672 0
gpio_imanager 16384 0
imanager_bl 16384 0
imanager_core 20480 5 i2c_imanager,gpio_imanager,imanager_hwmon,imanager_bl,imanager_wdt
root@tm-test:~/iManager# echo "0" > /sys/class/gpio/export
-su: echo: write error: Invalid argument
[ 134.037509] imanager_core: module verification failed: signature and/or required key missing - tainting kernel
[ 134.127820] imanager imanager: Found Advantech iManager it8528 - MIO-5271 13.14/1.0 (release)
[ 134.132421] imanager-gpio imanager-gpio: GPIO initialized with 8 pins
[ 134.193427] imanager-smbus imanager-smbus: SMBus frequency: 100 kHz
[ 134.338528] imanager-wdt imanager-wdt: Driver loaded (timeout=30 seconds)
[ 150.071675] export_store: invalid GPIO 1
[ 1021.013955] export_store: invalid GPIO 0
i have AIMB-274
and i can access 3 fan's rpm with windows driver
but with this driver i can olny access cpu fan's rpm and one 3pin fan's rpm
and i can access pch temperature and cpu temp with windows driver..
but only CPU temp with this driver.
windows drivers access extra register??
Dear Sirs,
We are running a linux 4.9.13 kernel on top of a AIMB-275 Mini-ITX motherboard.
The README of this module says AIMB board family have this kind of chip.
However the ec_read_chip function in imanager_init is returning ffff when loading the module.
(Below the log of modprobe printing the "No such device" error message)
It looks like there is no such chip at that address for our board.
Is there another iManager driver implementation?
How can we verify we have the Advantech EC based chip ITE IT8518 or IT8528?
Thank you for your support.
$ sudo modprobe -vvvv imanager-core
modprobe: INFO: ../libkmod/libkmod.c:354 kmod_set_log_fn() custom logging function 0x5563c0513090 registered
modprobe: DEBUG: ../libkmod/libkmod-index.c:790 index_mm_open() file=/lib/modules/4.9.13/modules.dep.bin
modprobe: DEBUG: ../libkmod/libkmod-index.c:790 index_mm_open() file=/lib/modules/4.9.13/modules.alias.bin
modprobe: DEBUG: ../libkmod/libkmod-index.c:790 index_mm_open() file=/lib/modules/4.9.13/modules.symbols.bin
modprobe: DEBUG: ../libkmod/libkmod-index.c:790 index_mm_open() file=/lib/modules/4.9.13/modules.builtin.bin
modprobe: DEBUG: ../libkmod/libkmod-module.c:529 kmod_module_new_from_lookup() input alias=imanager-core, normalized=imanager_core
modprobe: DEBUG: ../libkmod/libkmod-module.c:535 kmod_module_new_from_lookup() lookup modules.dep imanager_core
modprobe: DEBUG: ../libkmod/libkmod.c:544 kmod_search_moddep() use mmaped index 'modules.dep' modname=imanager_core
modprobe: DEBUG: ../libkmod/libkmod.c:392 kmod_pool_get_module() get module name='imanager_core' found=(nil)
modprobe: DEBUG: ../libkmod/libkmod.c:400 kmod_pool_add_module() add 0x5563c17c75c0 key='imanager_core'
modprobe: DEBUG: ../libkmod/libkmod-module.c:190 kmod_module_parse_depline() 0 dependencies for imanager_core
modprobe: DEBUG: ../libkmod/libkmod-module.c:556 kmod_module_new_from_lookup() lookup imanager_core=0, list=0x5563c17c76d0
modprobe: DEBUG: ../libkmod/libkmod-module.c:1707 kmod_module_get_initstate() could not open '/sys/module/imanager_core/initstate': No such file or directory
modprobe: DEBUG: ../libkmod/libkmod-module.c:1717 kmod_module_get_initstate() could not open '/sys/module/imanager_core': No such file or directory
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=bt87x mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=cx88_alsa mod->name=imanager_core mod-> alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=saa7134_alsa mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_atiixp_modem mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_intel8x0m mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_via82xx_modem mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_usb_audio mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_usb_caiaq mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_usb_ua101 mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_usb_us122l mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_usb_usx2y mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_cmipci mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_pcsp mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=snd_usb_audio mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=vmwgfx mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1355 kmod_module_get_options() modname=BOOT_IMAGE=/boot/vmlinuz_4 mod->name=imanager_core mod->alias=(null)
modprobe: DEBUG: ../libkmod/libkmod-module.c:1707 kmod_module_get_initstate() could not open '/sys/module/imanager_core/initstate': No such file or directory
modprobe: DEBUG: ../libkmod/libkmod-module.c:1717 kmod_module_get_initstate() could not open '/sys/module/imanager_core': No such file or directory
modprobe: DEBUG: ../libkmod/libkmod-module.c:717 kmod_module_get_path() name='imanager_core' path='/lib/modules/4.9.13/extra/imanager/imanager-core.ko'
modprobe: DEBUG: ../libkmod/libkmod-module.c:717 kmod_module_get_path() name='imanager_core' path='/lib/modules/4.9.13/extra/imanager/imanager-core.ko'
insmod /lib/modules/4.9.13/extra/imanager/imanager-core.ko
modprobe: DEBUG: ../libkmod/libkmod-module.c:717 kmod_module_get_path() name='imanager_core' path='/lib/modules/4.9.13/extra/imanager/imanager-core.ko'
modprobe: INFO: ../libkmod/libkmod-module.c:861 kmod_module_insert_module() Failed to insert module '/lib/modules/4.9.13/extra/imanager/imanager-core.ko': No such device
modprobe: ERROR: could not insert 'imanager_core': No such device
modprobe: DEBUG: ../libkmod/libkmod-module.c:441 kmod_module_unref() kmod_module 0x5563c17c75c0 released
modprobe: DEBUG: ../libkmod/libkmod.c:408 kmod_pool_del_module() del 0x5563c17c75c0 key='imanager_core'
modprobe: INFO: ../libkmod/libkmod.c:321 kmod_unref() context 0x5563c17c72b0 released
I am trying to build on ubuntu 18.04.5 and when running "sudo make install" I am getting the message:
make -C /lib/modules/5.4.0-74-generic/build M=/home/yoni/GIT/iManager modules
make[1]: Entering directory '/usr/src/linux-headers-5.4.0-74-generic'
Building modules, stage 2.
MODPOST 2 modules
make[1]: Leaving directory '/usr/src/linux-headers-5.4.0-74-generic'
make -C /lib/modules/5.4.0-74-generic/build M=/home/yoni/GIT/iManager INSTALL_MOD_DIR=extra/imanager modules_install
make[1]: Entering directory '/usr/src/linux-headers-5.4.0-74-generic'
INSTALL /home/yoni/GIT/iManager/i2c-imanager.ko
At main.c:178:
Trying to build on Debian 11.3. Fails with the following errors:
make[1]: Entering directory '/usr/src/linux-headers-5.10.0-13-amd64'
make[1]: Leaving directory '/usr/src/linux-headers-5.10.0-13-amd64'
rm -f -rf *.bak
make -C /lib/modules/5.10.0-13-amd64/build M=/home/john/iManager modules
make[1]: Entering directory '/usr/src/linux-headers-5.10.0-13-amd64'
CC [M] /home/john/iManager/imanager-core.o
/home/john/iManager/imanager-core.c: In function ‘imanager_register_cells’:
/home/john/iManager/imanager-core.c:806:13: error: assignment of read-only location ‘devs[i++]’
806 | devs[i++] = imanager_devs[IMANAGER_BACKLIGHT];
| ^
/home/john/iManager/imanager-core.c:809:13: error: assignment of read-only location ‘devs[i++]’
809 | devs[i++] = imanager_devs[IMANAGER_GPIO];
| ^
/home/john/iManager/imanager-core.c:812:13: error: assignment of read-only location ‘devs[i++]’
812 | devs[i++] = imanager_devs[IMANAGER_HWMON];
| ^
/home/john/iManager/imanager-core.c:815:13: error: assignment of read-only location ‘devs[i++]’
815 | devs[i++] = imanager_devs[IMANAGER_SMB];
| ^
/home/john/iManager/imanager-core.c:818:13: error: assignment of read-only location ‘devs[i++]’
818 | devs[i++] = imanager_devs[IMANAGER_WDT];
| ^
/home/john/iManager/imanager-core.c: In function ‘imanager_add_attribute’:
/home/john/iManager/imanager-core.c:222:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
222 | switch (attr->did) {
| ^~~~~~
/home/john/iManager/imanager-core.c:238:2: note: here
238 | case ADC:
| ^~~~
/home/john/iManager/imanager-core.c:239:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
239 | switch (attr->did) {
| ^~~~~~
/home/john/iManager/imanager-core.c:281:2: note: here
281 | case PWM:
| ^~~~
/home/john/iManager/imanager-core.c:282:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
282 | switch (attr->did) {
| ^~~~~~
/home/john/iManager/imanager-core.c:315:2: note: here
315 | case SMB:
| ^~~~
/home/john/iManager/imanager-core.c:316:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
316 | switch (attr->did) {
| ^~~~~~
/home/john/iManager/imanager-core.c:334:2: note: here
334 | case IRQ:
| ^~~~
make[3]: *** [/usr/src/linux-headers-5.10.0-13-common/scripts/Makefile.build:285: /home/john/iManager/imanager-core.o] Error 1
make[2]: *** [/usr/src/linux-headers-5.10.0-13-common/Makefile:1846: /home/john/iManager] Error 2
make[1]: *** [/usr/src/linux-headers-5.10.0-13-common/Makefile:185: __sub-make] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.10.0-13-amd64'
make: *** [Makefile:29: modules] Error 2```
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.