mavkhimenia has quit [Remote host closed the connection]
mavkhimenia has joined #linux-sunxi
leviathan has joined #linux-sunxi
d3r3k has quit [Quit: Connection closed for inactivity]
mavkhimenia has quit [Ping timeout: 264 seconds]
megi has joined #linux-sunxi
fkluknav has joined #linux-sunxi
mavkhimenia has joined #linux-sunxi
diego_r has joined #linux-sunxi
fkluknav has quit [Ping timeout: 240 seconds]
fkluknav has joined #linux-sunxi
fkluknav has quit [Ping timeout: 260 seconds]
matthias_bgg has quit [Ping timeout: 240 seconds]
mavkhimenia has quit [Remote host closed the connection]
mavkhimenia has joined #linux-sunxi
mhlavink has quit [Ping timeout: 264 seconds]
LargePrime has quit [Ping timeout: 256 seconds]
fkluknav has joined #linux-sunxi
mhlavink has joined #linux-sunxi
grw has quit [Ping timeout: 264 seconds]
fkluknav has quit [Ping timeout: 264 seconds]
lurchi_ is now known as lurchi__
fredl-pc has joined #linux-sunxi
JohnDoe_71Rus has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
fdcx has quit [Remote host closed the connection]
hardfalcon1 has joined #linux-sunxi
mavkhime_ has joined #linux-sunxi
fdcx has joined #linux-sunxi
mavkhimenia has quit [Ping timeout: 260 seconds]
hardfalcon has quit [Ping timeout: 248 seconds]
dddddd has joined #linux-sunxi
matthias_bgg has joined #linux-sunxi
mavkhimenia has joined #linux-sunxi
mavkhimenia has quit [Read error: Connection reset by peer]
mavkhime_ has quit [Ping timeout: 256 seconds]
mavkhimenia has joined #linux-sunxi
jbrown has quit [Ping timeout: 248 seconds]
elros has quit [Remote host closed the connection]
chomwitt has joined #linux-sunxi
f11f12 has joined #linux-sunxi
topi` has joined #linux-sunxi
<topi`>
has anybody ever implemented a linux-based "GPS tracker" device that would run on battery power and report the GPS pos to a backend every hour or so?
<topi`>
I wonder if OrangePi has any suitable model... but I am unsure how good the power cosumption characteristics are on the H3 series chips?
<topi`>
it would have to do very deep sleep... to compete with real microcontrollers
<miasma>
you'd want to use microcontrollers
<KotCzarny>
+1
<KotCzarny>
gps tracker can log data and periodically wake communication board probably
<topi`>
miasma: I don't want to handle non-linux software
<miasma>
the microcontrollers have very lightweight software stack
<topi`>
KotCzarny: I'd setup a timer to wake up linux every 3600 seconds, and do some stuff and decide whether or not it's worthwhile to fire up 2G and contact backend
<miasma>
there are some gps-uart modules for arduino and compatibles
<miasma>
i got one sample for free
<topi`>
miasma: yeah, I understand that, but my skill set is totally outside of building software for arduinos
<KotCzarny>
H3 board in deep sleep is ~50-100mA
<miasma>
i'd argue those are easier to use than opi
<topi`>
the only way I could do that would perhaps be using micropython and it's IP+ssl stacks :)
<KotCzarny>
so quite a lot
<topi`>
KotCzarny: ok, then we can rule out H3 boards :( well, it's better than the raspi boards, but still ...
<miasma>
topi`: you could collect the coordinates with the micro-controller and start h3 when the buffer is full
<KotCzarny>
thats why one should use uc for such tasks (or big battery)
<topi`>
funny, I would have thought that somebody would already have done this on top of linux :) there are all kinds of very small linux chips, like Atmel SAMA5D2
<KotCzarny>
you can always buy some older android phone and nuke gui
<KotCzarny>
;)
<topi`>
KotCzarny: yeah, maybe there are some more or less ready sw packages for flashing on MCUs with this ARM mbed stuff
<miasma>
topi`: what kind of battery life you would want
<topi`>
I despise android
<topi`>
miasma: well perhaps some big lithium (not lithium ion) buttons in parallel, so quite comparable to a modern smartphone
<miasma>
but in hours?
<topi`>
then if you wake it up once an hour, it can probably go for an entire year if the sleep usage is small enough
<f11f12>
miasma: whatever you get out of a lead acid car battery :-)
<topi`>
maybe a year is just fantasy, though
<miasma>
might be possible with bigger li-ion cells and a micro-controller
<KotCzarny>
topi`: you might despise android, but you can use it's linux layer to do what you like
<topi`>
yeah, I'm sure the chinese have already commercialiced many sorts of "gps trackers"
<topi`>
KotCzarny: yeah. I was very depressed to learn about the pmOS project (postmarket linux OS for smartphones) and the device matrix listed only ONE device that had working cellular data - Nokia N900
<topi`>
everything else - not supported
<KotCzarny>
oh yeah, if you can, use n900 for your project
<topi`>
what about the OPI 2G-IOT board that I saw some article about one year ago? Is that based on an Allwinner chip?
<KotCzarny>
you dont need postmarket os, it's linux already
<KotCzarny>
and if you use higher cap (or double battery) you might get few weeks of uptime
<KotCzarny>
opi 2g is not allwinner
<miasma>
topi`: if you need to start the device every hour for 10 seconds, you'd need to power on the device for 24 hours during a year. that would be doable with e.g. esp8266 and a single 18650 cell
<topi`>
KotCzarny: then probably no mainline linux support?
<KotCzarny>
topi`: if you dont need voice, almost everything is mainlined
<KotCzarny>
there is already alfa os based on that (codenamed leste)
<topi`>
miasma: I was thinking of some STM32F3 chip, that's the only thing I have some experience with
<topi`>
KotCzarny: oh, interesting, maybe that's worth a look even though it might not work for this particular use case
<miasma>
prolly works too. you don't need much resources unless you store the data locally
<KotCzarny>
but even 2.6.28 could work fine for your case
<topi`>
2.6?? *shudder*
<KotCzarny>
you only need hw working, right?
<topi`>
I want a modern linux stack
<topi`>
well, not the whole stack. Just busybox
<KotCzarny>
then yeah, look into leste (or just kernel and create something yourself)
<topi`>
you build busybox with python, and you can do just about every imaginable thing
<miasma>
python is pretty bloated compared to busybox+kernel
sunshavi has joined #linux-sunxi
<miasma>
kernel+initramfs+busybox ~3MB. my python2 package is 73 MB
<topi`>
well, the kernel can eat up 4MB of ram, just the same as with CPython
<topi`>
I can build python to carry just the stuff I happen to need
<topi`>
anyways, 256MB of storage is probably not a problem if the device can run Linux in the first place
<KotCzarny>
n900 has 256M of nand, but 32GB of emmc
<topi`>
I don't want to take the discussion to this direction. Eeveryone has their pet peeves. I just want to see how low can a cortex-a series processor go while in deep power save
<KotCzarny>
my current phone does 10mA in idle with gsm connected and display off
<KotCzarny>
can go to 7mA sometimes
<KotCzarny>
(n900)
<topi`>
ideally, I'd just shut down the regulator totally that supplies the 2G chip
<KotCzarny>
yes, you can turn off modem
<KotCzarny>
but you should ask on #maemo if it turns off wholly
<topi`>
the OPI-2G thingy looks interesting, but is there any kind of community behind that strange RDA chip?
<beeble>
stm32f7 <2mA at suspend to ram. so maybe get a disco board
<beeble>
and yes they are running linux
<beeble>
mainline
<topi`>
the biggest advantage of Allwinner is the community
<miasma>
topi`: if you have time, would be interesting to know though, which of the small h2+/h3 boards consumes less power. there are multiple models. both from nanopi and orange pi
<miasma>
the smallest is the same size as esp8266 nodemcu
<KotCzarny>
miasma: i wouldnt suspect big differences between boards (unless badly designed)
<KotCzarny>
it's the soc+ram that eats most
<topi`>
yeah, DRAM is a battery drain
<topi`>
possibly if you have less (like 64MB), it can consume less
<topi`>
IDK
<miasma>
KotCzarny: does nanopi and opi boards use the same dram chips
cnxsoft has quit [Quit: cnxsoft]
<KotCzarny>
well, if you can squeeze your app into 32kB, you can run off sram and openrisc core
<miasma>
gps data wouldn
<miasma>
wouldn''t probably need 64 MB :D
<topi`>
you can't squeeze a linux kernel into 32K sram :)
<KotCzarny>
miasma: all you need is to read serial port and save that data somewhere, right?
msimpson_ has joined #linux-sunxi
<topi`>
the cheapest way is to write data periodically to flash, and then sleep some more
<KotCzarny>
topi: if you know tiny bit of C you can write your app to run off openrisc core
mavkhime_ has joined #linux-sunxi
<topi`>
KotCzarny: are there any openrisc boards?
<KotCzarny>
and it would be perfectly fine
<miasma>
if you don't need realtime access to the data, i'd probably use arduino + gps uart + sd card reader. there's plenty of code for all those
<KotCzarny>
topi`: H3 includes openrisc core
<topi`>
KotCzarny: I'm not going to touch C again, I just learned myself some rust and it kicks some serious ass in systems programming
<KotCzarny>
so you can turn off everything else (dram too) and run only o n that
<topi`>
KotCzarny: wow! I didn't know that
<topi`>
KotCzarny: does the openrisc core have any I/O? to be able to snoop if there's an interrupt coming off of the GPS chip
<KotCzarny>
yup, and you can access any interface you want
<topi`>
well that's a game changer
<KotCzarny>
but obviously you would have to service it yourself, no linux, no drivers
<topi`>
I can make the linux kernel sleep as long as necessary and only wake it up when some event occurs
<KotCzarny>
only registers
<topi`>
if the sleep is long enough, write the whole contents of DRAM to NAND, and re-read it before resuming linux
<KotCzarny>
and if you connect some gsm module that has simple serial interface, you can buffer some data and then send it off
<topi`>
I wonder if some kind of generic hypervisor could be built on top of this openrisc core
<KotCzarny>
any
<KotCzarny>
but you are limited by how much power you want to draw
<topi`>
the only interesting sensor data is coming off of a GPS chip.
<topi`>
if the darn thing moves, then the GPS will issue an iterrupt
msimpson has quit [Ping timeout: 256 seconds]
mavkhimenia has quit [Ping timeout: 240 seconds]
<topi`>
the domain for this "gps tracker" is stationary equipment which is not expected to move at all
<miasma>
but it should report every hour?
mavkhimenia has joined #linux-sunxi
<topi`>
no, only if the GPS pos has changed
<miasma>
ok. that would help a lot with the power requirements
mavkhim__ has joined #linux-sunxi
<miasma>
but you might also want some kind of heartbeat msg to see the device is still active
<topi`>
probably with a very long time timer
<KotCzarny>
still, it would draw ~50mA
<topi`>
another approach would be to shutdown the board and set up a timer to reset the board after a few hours or so
<topi`>
but booting up linux does require quite a lot of electrons
<KotCzarny>
maybe there is some way to sleep whole chip with self wake
<topi`>
KotCzarny: i think most of those ~50 mA can be shaved off if the DRAM can be powered down
<KotCzarny>
nope. it's with dram and arm cores off
mavkhime_ has quit [Ping timeout: 240 seconds]
<topi`>
oh, that's quite a lot still
<KotCzarny>
i was trying to find lowest i can go while still having access to it
mavkhime_ has joined #linux-sunxi
<topi`>
KotCzarny: with or without linux kernel?
<KotCzarny>
(i wrote h3fakeoff to simulate off state with events turning thing on (gpio/ir/wol etc)
<KotCzarny>
baremetal app
mavkhimenia has quit [Ping timeout: 240 seconds]
<KotCzarny>
it uses ~10kB of those 32kB
<KotCzarny>
so plenty of ram to write additional modules
<topi`>
so the openrisc core inside H3 has 32K of SRAM?
<miasma>
arduino pro mini @ 1MHz uses 0.5 mA when active :)
<KotCzarny>
no, soc has sram, both openrisc and arisc can almost everything
<KotCzarny>
*use
<KotCzarny>
for simplicity and power saving i dont use dram (unless wol is requested)
megi has quit [Ping timeout: 264 seconds]
<topi`>
yeah, setting up DDR can be tricky
mavkhim__ has quit [Ping timeout: 248 seconds]
<KotCzarny>
it is, i cheat by having it already enabled and just disabling when no wol needed
<topi`>
KotCzarny: on which board did you measure 50 mA?
<topi`>
maybe there was power still enabled to some sections/chips
<KotCzarny>
i think it was opipc
<topi`>
not everything is behind a regulator
popolon has joined #linux-sunxi
<KotCzarny>
yeah, i leave usb0 and uart running
<topi`>
usb controllers can be hungry
<KotCzarny>
usb0 is otg
<topi`>
even the uart will take some milliamps
<topi`>
I think
<topi`>
even while idle
<KotCzarny>
measuring power is also tricky, because those board steal power from everywhere, uart included
<KotCzarny>
bbl
sunshavi has quit [Quit: restart]
sunshavi has joined #linux-sunxi
d3r3k has joined #linux-sunxi
mavkhimenia has joined #linux-sunxi
Igor2 has joined #linux-sunxi
mavkhime_ has quit [Ping timeout: 240 seconds]
<Igor2>
hi all; I have an orange pi pc 1.2, armbian with mainline kernel; how can I set HDMI resolution to 1024x768?
LargePrime has joined #linux-sunxi
matthias_bgg has quit [Quit: Leaving]
fkluknav has joined #linux-sunxi
f0xx has quit [Ping timeout: 248 seconds]
msimpson_ has quit [Ping timeout: 240 seconds]
aalm has quit [Ping timeout: 240 seconds]
<diego71>
Igor2: have you tried xrandr?
<Igor2>
no X yet, I'd like to get the console to work properly
<diego71>
Igor2: there is also fbset if I remember well
<Igor2>
(my monitor can't display anything at 1920x1080 and it seems whatever I try, /boot env settings, fbset, etc, the dirver keeps the resolution)
<KotCzarny>
igor2: shouldnt it auto detect resolution?
<Igor2>
yup, but fbset does not change the mode
<Igor2>
it probably should, but despite of the edid (decoded from /sys) looks good for the monitor, even has the model and serial of the monitor, it is trying to set an invalid resolution
<KotCzarny>
what res it uses in uboot?
<Igor2>
probably the same invalid res
<Igor2>
I never have any valid screen on the monitor, I can trace only through the serial line
<KotCzarny>
any vga--hdmi adapter?
<Igor2>
yup, hdmi<->vga adapter
<KotCzarny>
try another
<Igor2>
no, thanks
<Igor2>
I just want to force a resolution
<Igor2>
I don't need it to be automatic
<KotCzarny>
then xrandr (assuming you are in x)
<Igor2>
I just want to tell uboot or the kernel or whatever that sets the resolution to set 1024x768, I know the timings, etc
<Igor2>
sorry, I want the console to work
<Igor2>
X is secondary in my use case
LargePrime has quit [Ping timeout: 260 seconds]
mavkhimenia has quit [Remote host closed the connection]
mavkhimenia has joined #linux-sunxi
<Igor2>
I can try if xrandr affects the console too, but I would be really really surprised
<KotCzarny>
nah, kernel would switch to console res when changint vt
<Igor2>
yup, that'd kill it
<Igor2>
does this work with the legacy kernel?
<Igor2>
because then I switch back to the legacy
<KotCzarny>
legacy uses fex's set mode
iamfrankenstein has quit [Ping timeout: 240 seconds]
<Igor2>
has anyone seen manually set modes working on H3 chips and HDMI?
<KotCzarny>
i just set it in fex
<KotCzarny>
less hassle and reliable
<Igor2>
ok, so you say manually set video mode works for you with fex
<Igor2>
then I'm going to download the legacy stsem
<KotCzarny>
fbset should work in your case with maunline tho
<KotCzarny>
*mainline
mavkhimenia has quit [Ping timeout: 256 seconds]
<Igor2>
it doesn't
<Igor2>
at least -xres -yres doesn't
<Igor2>
-pixelclock gives ioctl error
<mripard_>
you cannot change the framebuffer resolution
<mripard_>
at runtime at least
<Igor2>
(I also never managed to get fbset to actually change physical resolution on dekstop pc either, so I'd be surprised if it worked on arm)
<KotCzarny>
mripard_: can it be setto lower res?
<mripard_>
you can change it at boot if you want though through the video= kernel parameter
<Igor2>
btw, I don't really need to be able to change it runtime, it's fine if I can hardwire the good values once on boot
<mripard_>
and yeah, that is for the same reason than on desktop
<Igor2>
mripard_, thanks, I tried that bit it got silently ignored
<mripard_>
both are using DRM drivers
<mripard_>
the fbdev interface is an emulation, legacy one
<Igor2>
the kernel command line got the parameters I wrote in there
<mripard_>
and the emulation isn't full featured
<Igor2>
but the actual hdmi output remained 1920x1080
<mripard_>
Igor2: what value did you set?
<Igor2>
let me boot it to see
<Igor2>
i experimented with disp_mode and video-mode, not sure which one should be used (as many documentation I find each does something different on this)
<Igor2>
1024x786,monitor=hdmi,hdp=0,edid=0
<Igor2>
this was for video-mode
<mripard_>
this is U-boot, not the kernel
<Igor2>
disp_mode=1024x768-24@60
<Igor2>
edid=0
<Igor2>
hdp=0
<Igor2>
could you please give me a config line then?
<Igor2>
(yes, uboot, as far as I understood it's uboot that sets it up and then the kernel inherits it, so if I don't have it right in uboot, I won't be able to fix in the kernel - at least some sources suggest that)
<diego71>
Igor2: yes, if you use fbsimple
LargePrime has joined #linux-sunxi
<Igor2>
I could, if that works... just tell me a combination that is known to work, and I am going to use that
mavkhimenia has joined #linux-sunxi
Putti has quit [Ping timeout: 264 seconds]
<jernej>
Igor2: Can you tell the exact kernel version?
tllim has joined #linux-sunxi
<Igor2>
jernij, 4.14.14-sunxi
<jernej>
Igor2: regarding U-Boot, you can't force resolution currently on H3
<jernej>
or A64 or H5
<Igor2>
ohh :(
<Igor2>
can I get the kernel to change resolution?
msimpson_ has joined #linux-sunxi
<Igor2>
(it's enough if it happens on boot, I don't need to be able to change runtime)
<jernej>
I think you can override edid informations
<jernej>
I never done it myself, but I read about it
<jernej>
let me check
<Igor2>
thanks!
<Igor2>
I managed to read out edid from /sys, but didn't see any override file there
fkluknav has quit [Ping timeout: 248 seconds]
<jernej>
you can't see override there since it's kernel argument