Sxmo - Simple X Mobile Released for the Pinephone (new minimalistic UI & image)
(12-27-2020, 06:10 AM)lat Wrote: 1. ring
Code:
mpv --loop ringtone1.wav

These work well, except when I miss the incoming call - the phone keeps ringing indefinitely.  Is another hook required?  How to do it in order to stop the phone ringing on a missed call?
 
maybe try setting a number for the --loop option
for ring I have: mpv --no-resume-playback --loop=2 --vid=no /usr/share/sounds/ring.mp3
(12-27-2020, 06:10 AM)lat Wrote:
(12-22-2020, 10:39 PM)hiimtye Wrote: user guide lists some files to put scripts into that you can add a one liner to play an audio file using your favourite lightweight player for sms and calls
Thanks for the tip!  Now, I have 2 scripts:
1. ring
Code:
mpv --loop ringtone1.wav
2. pickup
Code:
pkill mpv
These work well, except when I miss the incoming call - the phone keeps ringing indefinitely.  Is another hook required?  How to do it in order to stop the phone ringing on a missed call?

This is what I have in ring and pickup hooks. This checks if incoming call is still active and stops ring when the call has disconnected.

ring:-
Code:
#!/usr/bin/env sh


incallmonitor() {
        CALLRINGING=$(mmcli -m "$(modem_n)" --voice-list-calls)    
        echo $CALLRINGING
                if [[ "$CALLRINGING" == "No calls were found" ]]; then
                    exit 1
        fi
}
modem_n() {
        MODEMS="$(mmcli -L)"
        echo "$MODEMS" | grep -qoE 'Modem\/([0-9]+)' || finish "Couldn't find modem - is your modem enabled?"
        echo "$MODEMS" | grep -oE 'Modem\/([0-9]+)' | cut -d'/' -f2
}


sxmo_audioout.sh Speaker
amixer sset 'Line Out' 100%
while true; do
    mpv /home/mo/Music/message_tone.mp3 --no-video
    sxmo_vibratepine 1000
    notify-send $1
    incallmonitor "$1"
done




pickup:-
Code:
ID=$(ps -ef|grep ring|grep -v grep|perl -ne '$_=~ m/^ *(.*) mo.*/;print $1')
kill -9 $ID
pkill mpv
sxmo_audioout.sh
Thank you @aithal and @saba!

Has anyone encountered and tackled the issue of non-english sms not displaying?
"--" is displayed instead of any message cointaining non-english characters.
you could do something like

Code:
mpv --loop ringtone1.wav &
sleep 30 && kill $!

unless there's some sort of hook for the modem hanging up, I haven't looked very far into it (I haven't at all)


on unrelated news, last night I got the "no space left on device" error while upgrading the kernel. it is indeed /boot, so I'm going to double the size of /boot and see if that prevents it from happening in the future

(12-27-2020, 09:52 AM)lat Wrote: Thank you @aithal and @saba!

Has anyone encountered and tackled the issue of non-english sms not displaying?
"--" is displayed instead of any message cointaining non-english characters.
I have that for random messages. it could be non-standard characters being displayed. for instance, when my 11 year old daughter texts from her grandmother's phone, I assume there's a lot of emojis inside, and all I receive is --

I thought it was still pending as the service in my area sucks, but it didn't resolve itself when I got better service.


update: resizing /boot to 1024mb seems to have resolved the out of space error, hopefully it won't creep up again.

anyone having problems with svkbd? mine will pop up with single press of the power button, but it won't close it. furthermore, the keyboard that pops up on the login screen is owned by root, so I have to use sudo to kill it.
so I made a .config/sxmo/xinit to set some variables. I'm interested to see what effect it will have on my battery/behaviour.


Code:
#!/usr/bin/env sh
# make Firefox our default browser on long press power
export BROWSER=firefox

#Temporarily wake every 15 minutes during sleep
export SXMO_RTCWAKEINTERVAL=900

# set editor
export EDITOR=vim

# set default lock to suspend to save me clicks
export SXMO_LOCK_SUSPEND=1

# set dmenu to wrap to/from bottom/top to save me clicks and the life of the side buttons
export DMENU_WRAP_AROUND=true

# path to save audio recordings to (scripts menu)
export SXMO_RECDIR="/home/mo/Audio/Recordings/"

# toggle modem on login
# sleep for 15 seconds to give the modem a chance to appear
# background entire process so that it doesn't stall loading the UI
(sleep 15; sxmo_modemmonitortoggle.sh on) &

update: I was looking for a podcast app and then I realized that there's an RSS script by default, so I went ahead and made an sfeedrc by copying the existing one. I edited it to contain only the ones I was interested in, and added my own. when I run the RSS script, it tells me the status of each of the feeds from my sfeedrc, but when it comes time to show the list of feeds, it's the list of feeds from the default sfeedrc. I'm dumbfounded by this. the feeds are downloaded into ~/.sfeed/feeds and I made sure that the old entries from the original run of the script were removed so it's only my feeds listed.
(12-27-2020, 09:52 AM)lat Wrote: Thank you @aithal and @saba!

Has anyone encountered and tackled the issue of non-english sms not displaying?
"--" is displayed instead of any message cointaining non-english characters.

Yes, this is being handled upstream by ModemManager. See https://gitlab.freedesktop.org/mobile-br...issues/274 and https://gitlab.com/postmarketOS/pmaports/-/issues/861
(12-28-2020, 02:12 PM)hiimtye Wrote: update: I was looking for a podcast app and then I realized that there's an RSS script by default, so I went ahead and made an sfeedrc by copying the existing one. I edited it to contain only the ones I was interested in, and added my own. when I run the RSS script, it tells me the status of each of the feeds from my sfeedrc, but when it comes time to show the list of feeds, it's the list of feeds from the default sfeedrc. I'm dumbfounded by this. the feeds are downloaded into ~/.sfeed/feeds and I made sure that the old entries from the original run of the script were removed so it's only my feeds listed.

Make sure the feeds directory is properly set in your sfeedrc, and double check whatever sfeed viewing script you're using is going to that directory.


Possibly Related Threads…
Thread Author Replies Views Last Post
  PostmarketOS sxmo pinephone keyboard keymaps? afwtioane 2 1,947 09-11-2022, 04:37 AM
Last Post: manubert
  sxmo pim nextcloud Uturn 8 5,829 02-22-2022, 03:23 PM
Last Post: TRS-80
  Battery life on sxmo xark 1 2,028 02-12-2022, 10:07 AM
Last Post: TRS-80
  Official Channels for Sxmo Support anjanmomi 2 2,991 02-12-2022, 09:50 AM
Last Post: TRS-80
  sxmo & php --- 2 1,707 01-31-2022, 01:45 PM
Last Post: ---
  sxmo improvements unrealb2 7 5,500 11-17-2021, 06:43 AM
Last Post: fdlamotte
  SXMO on Debian IVp 0 2,114 08-21-2021, 02:33 PM
Last Post: IVp
  Megi's multiboot sxmo image aithal 1 2,126 06-14-2021, 08:07 AM
Last Post: fdlamotte
  SXMO svkbd with joypad layout [for basic dosbox play] streak 0 1,440 05-27-2021, 08:47 AM
Last Post: streak
  Sxmo on Arch IVp 4 6,254 05-19-2021, 03:18 AM
Last Post: dukla2000

Forum Jump:


Users browsing this thread: 1 Guest(s)