https://wiki.pine64.org/api.php?action=feedcontributions&user=Silver&feedformat=atomPINE64 - User contributions [en]2024-03-28T09:02:32ZUser contributionsMediaWiki 1.37.1https://wiki.pine64.org/index.php?title=PinePhone_(Pro)_Keyboard&diff=12502PinePhone (Pro) Keyboard2022-02-12T07:09:50Z<p>Silver: /* Safety */ Added a link to my toot with the phone port taped over</p>
<hr />
<div>[[File:PP_KB_Front-1024x576.jpg|400px|thumb|right|Picture of the PinePhone (Pro) Keyboard]]<br />
<br />
The '''PinePhone (Pro) Keyboard Case''' is a case compatible with the [[PinePhone]] and [[PinePhone Pro]], adding a keyboard functionality to the phone. It features a clam-shell design and uses the pogo pins located on the smartphone’s midsection and attaches by replacing the default back cover. This add-on effectively turns the PinePhone (Pro) into a PDA with an in-built LTE modem.<br />
<br />
== Getting started ==<br />
[[File:Ppkb_description.png|thumb|upright=1.2|<br />
① Contact pads<br><br />
② Battery switch<br><br />
③ USB-C connector]]<br />
<br />
The keyboard case works with both the PinePhone and PinePhone Pro and features a clam-shell design. It uses pogo pins located on the phone’s midsection and attaches by replacing the default back cover. When folded, the phone’s screen and the keyboard rest securely against each other. The hinge features a 180° design, which not only allows for two-hand typing on a surface but also for comfortable thumb-typing when fully extended. The etched keycaps can be easily relocated for alternate layouts such as AZERTY or QWERTZ. The keyboard case runs an [https://xff.cz/git/pinephone-keyboard/ open firmware], which means that anyone with the know-how can alter existing functions or add new ones. The bottom (keyboard) and top (phone) sections of the assembly are well-balanced thanks to the large, 6000mAh, internal battery capable of charging the PinePhone (Pro) during operation. The internal battery effectively triples the phone’s battery life. The internal keyboard battery can be manually toggled on/off and the keyboard’s battery charge level can be read in the supported OSes; the keyboard remains functional with the battery fully depleted.<br />
<br />
You do not lose access to the PinePhone (Pro)’s USB-C port, speaker, microphone, or any external features, such as volume and lock buttons, with the keyboard attached. There is also a cut-out for the camera, torch, and headphone jack. The USB-C port on the keyboard is capable of powering both the keyboard and PinePhone (Pro) simultaneously. This means that you can plug in a USB mouse, a USB-C dongle, or some other peripheral while the phone and keyboard’s internal battery charge ('''warning:''' it is highly advised to read the [[PinePhone (Pro) Keyboard#Safety|safety]] section prior doing this). Please keep in mind that the keyboard case transforms the PinePhone (Pro) into a PDA, which means that taking calls will likely prove awkward without a wired or wireless headset connected.<br />
<br />
=== Mounting the keyboard ===<br />
Power off your PinePhone and remove the back case. To remove the back case of the PinePhone use your fingernail or another soft object to pry up the back case. A notch to easily remove the cover is located at the bottom left of the PinePhone with the backcover facing the user. <br />
<br />
Open and place the keyboard flat on a hard surface with the hinge fully extended. Proceed to insert the PinePhone into the keyboard at an angle of approx. 15 degrees. Make sure that the PinePhone’s pogo pins and the corresponding pads ① on the keyboard are aligned. The leading edge with volume and power buttons should make contact first. Firmly press the PinePhone into place. Multiple clicks should be heard as the two snap into place. Pay special attention to the plastic pin below the camera hole. Firmly push from the rear, below the camera hole, to click it into position. Failing to do so may cause an insufficient pin contact and prevent the case from charging the phone.<br />
<br />
The PinePhone can be removed from the keyboard easily using a notch similar to the one found on the back case. The notch is located at the bottom of the leading edge with the power and volume buttons.<br />
<br />
=== Operation ===<br />
The keyboard will function automatically once a PinePhone running a compatible operating system is mounted. For alterations to physical layout and firmware see the relevant sections respectively.<br />
<br />
The keyboard features an in-built 6000mAh battery. The battery can be turned ON/OFF using the button on the right leading edge of the keyboard ②. A short button press activates the internal battery while a long (15 seconds) press deactivates it. Compatible operating systems display both the PinePhone’s and keyboard’s battery status.<br />
<br />
You should charge the PinePhone and the keyboard <u>only</u> using the USB-C ③ port on the keyboard. The keyboard’s USB-C port cannot be used for peripherals. The PinePhone’s USB-C port remains operational when mounted in the keyboard and can be used for data and peripherals.<br />
<br />
=== Troubleshooting ===<br />
There are multiple possible hardware issues users could face. It is recommend to check the following most common hardware issues and their solutions and workarounds.<br />
<br />
==== Pogo pins not making proper contact ====<br />
Under certain scenarios the keyboard's contacts are not making proper contact with the pogo pins of the phone. To address the issue:<br />
<br />
* Power down the phone!<br />
* Apply '''slight''' pressure in the upper mid of the PinePhone's backside until the plastic holder pin towards the upper middle of the keyboard cover, until an audible click can be heard.<br />
* Make sure the contacts and pogo pins are clean and the pogo pins can be slightly pressed individually.<br />
* If the above does not work, a shim under the keyboard's contacts might be required, as explained [https://xnux.eu/pinephone-keyboard/faq.html#ts FAQ troubleshooting section]. See also this [https://freiburg.social/system/media_attachments/files/107/684/243/421/870/279/original/a5e9c68ff3510ec8.jpeg photo of where to place the shim]<br />
<br />
==== Top row is less responsive ====<br />
The keys of the top row may be less responsive. The issue can be worked around by adding inserts to the underside of the top row key caps to decrease the travel distance. More details regarding the workaround can be found in the corresponding section of the FAQ page of the developer megi: https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
==== Software issues ====<br />
For any software issue please see the [[PinePhone (Pro) Keyboard#Software support|Software support section]] and the [[PinePhone (Pro) Keyboard#Frequently asked questions|FAQ section]].<br />
<br />
== Safety ==<br />
{{Under construction}}<br />
<br />
{{warning|1=Do NOT plug any power source into the phone USB-C port while the keyboard is attached. Doing so may result in damage or loss of the keyboard charging functionality.}}<br />
<br />
Silver put tape over the port to remove the possibility of accidentally plugging power into the wrong port. Pictures on mastodon: https://fosstodon.org/web/@silverhax/107783280758831068<br />
<br />
{{warning|1=Do NOT lube the keyboard with GPL 205G0 switch grease. It can cause problems with the key responsiveness and tactility.}}<br />
{{hint|Only use mild isopropyl alcohol when wiping down the clamshell of the device. Stronger solutions may partially strip the coatings.}}<br />
<br />
== Software support ==<br />
<br />
=== Kernel-space driver ===<br />
<br />
Kernel driver implementation from Samuel Holland: ip5xxx_power and kb151 https://github.com/smaeul/linux/commits/wip/pp-keyboard<br />
<br />
=== User-space driver ===<br />
The user-space driver is available [https://xff.cz/git/pinephone-keyboard/ here]. Use git to clone the repository. You're going to need sdcc 4.1+ installed to build it, so use your package manager to install that first. Next you'll cd into the directory you cloned pinephone-keyboard and use the command "make" to build. After the build is completed, cd into the build directory and you'll notice several new files starting with ppkb-. To use your keyboard case, you'll want to run the following command: <code>sudo ./ppkb-i2c-inputd</code> <!-- this isn't running as a daemon, if anyone knows how to make it do so please edit that info in! --> Open something you can type into like a new terminal window or text editor and you should now be able to use the keyboard case! <br />
<br />
=== Notes ===<br />
Virtual keyboards such as <i>squeekboard</i> are opening whenever a text field is selected.<br />
<br />
To disable this behavior under GNU/Linux running Phosh, you can run the following: <br />
<br />
To disable the virtual keyboard: <code>gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled false</code><br />
<br />
To enable the virtual keyboard: <code>gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled true</code><br />
<br />
The virtual keyboard needs to be activated before removing the keyboard case again, however this setting observed not to persist between reboots in pmos but be warned regardless that you do need a keyboard of some kind to log in.<br />
<br />
A setting to disable the keyboard can be found in Settings -> Accessibility -> Screen Keyboard according to https://forum.pine64.org/showthread.php?tid=15789&pid=105152<br />
<br />
The keyboard can be disabled in plasma via widget https://forum.pine64.org/showthread.php?tid=14789&pid=105077#pid105077<br />
<br />
In sxmo keyboard disable is not needed, keyboard only shown when power pressed (X11 pmos and according to old documentation) or vol down pressed (wayland pmos, new default?)<br />
<br />
== Keyboard layout ==<br />
The keyboard features a default layout (pictured below) created and agreed upon by the community. The keyboard layout can be altered using software as well as by physically repositioning keycaps. All keycaps, with the <u>exception</u> of space and return keys, can be easily and safely relocated for alternative layouts corresponding to software settings.<br />
<br />
<gallery mode="nolines" widths="500px" heights="400px"><br />
Image:Ppkb_layout2.png|The keyboard layout how the keys were originally intended<br />
</gallery><br />
<br />
== Keyboard firmware ==<br />
PinePhone’s keyboard firmware was developed independently by Ondřej Jirman as a free-of-charge contribution to PINE64. The firmware source code is freely and publicly available and you can modify it, and the supporting utilities, using common FOSS tools. <br />
<br />
=== Firmware and supporting utilities ===<br />
The design of the firmware allows the keys, modifier keys, and their combinations to be handled in virtually unlimited ways, without a need to flash a customized version of the firmware. Mapping of keys is defined at runtime, using the supporting utilities, and is not hardcoded in the firmware. Different keyboard layouts can be loaded dynamically to support various use cases.<br />
<br />
The repository that contains the source code of the firmware, supporting utilities and associated documentation is located at https://xnux.eu/pinephone-keyboard/.<br />
<br />
You are welcome to contribute patches and improvements to the firmware and the supporting utilities. A summary of firmware development history is available at https://xnux.eu/log/ alongside other development updates from the firmware author.<br />
<br />
Much time and effort went into the development of this firmware. If you wish to send a token of appreciation or support the development efforts in any way, please consider making a donation to the author via one of the methods listed at the bottom of this web page: https://xnux.eu/contribute.html.<br />
<br />
=== Firmware License ===<br />
<br />
<blockquote>Copyright (C) 2021 Ondřej Jirman <megi@xff.cz><br />
<br />
This program is free software: you can redistribute it and/or modify<br />
it under the terms of the GNU General Public License as published by<br />
the Free Software Foundation, with either version 3 of the License or<br />
(at your discretion) any later version.<br />
<br />
This program is distributed in the hope that it will be useful,<br />
but WITHOUT ANY WARRANTY; without even the implied warranty of<br />
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. <br />
See GNU General Public License for more details.<br />
<br />
GNU General Public License http://www.gnu.org/licenses/</blockquote><br />
<br />
== Hardware ==<br />
Key hardware specifications:<br />
* Dimensions (closed): 161 x 95 x 21.5mm<br />
* Weights (without / with PinePhone mounted): ~ 191 / ~391 grams<br />
* Number of keys: 54<br />
* Number of rows: 5<br />
** Keyboard IC: Keyboard IC: EM85F684A 8-bit microcontroller with 256 bytes RAM, 2048/ bytes XRAM; 16kB for user’s own firmware<br />
* Battery capacity: 6000mAh (22.2Wh 3.7V)<br />
* Charger input: 5V, 3A (15W)<br />
** Charging and battery IC chip: IP5209 power management IC with charge indicate controller and boost converter<br />
<br />
== Frequently asked questions ==<br />
{{Under construction}}<br />
<br />
''' The keyboard does not work under OSK-SDL (full-disk encryption UI at boot) '''<br><br />
That is a known bug, see https://gitlab.com/postmarketOS/pmaports/-/issues/1383.<br />
<br />
''' What is the keyboard driver situation? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#drivers<br />
<br />
''' Are keyboard drivers included in my distribution? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#distros<br />
<br />
''' What's the status of the existing software for the keyboard? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#sw-status<br />
<br />
''' My keyboard doesn't work (well)! '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#faq-ts<br />
<br />
''' How does charging work? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#charging<br />
<br />
''' What charger is best for the keyboard? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#chargers<br />
<br />
''' How safe is the charger circuit in the keyboard? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#safety<br />
<br />
''' Keyboard doesn't react to any key presses '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Keyboard works but top row of keys is less responsive '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Phone is not charging from the keyboard '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Phone is charging slowly from the keyboard battery '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Can you open the keyboard and add extra functionality? '''<br><br />
It is possible to do so, however the production units can be extremely difficult to open. Do not attempt to open the keyboard if you do not want to risk cosmetic damage (scaring and scratching of the plastic).<br />
<br />
== Documents ==<br />
<br />
* [https://files.pine64.org/doc/PinePhone/USER%20MANUAL-KEYBOARD-V2-EN-DE-FR-ES.pdf PinePhone Keyboard 4 language user manual ver 2.0 in PDF format]<br />
* [https://files.pine64.org/doc/PinePhone/USER%20MANUAL-KEYBOARD-V2-EN-DE-FR-ES.odt PinePhone Keyboard 4 language user manual ver 2.0 in ODT format]<br />
<br />
== Schematics, Datasheet and certifications ==<br />
<br />
* Schematic:<br />
** [https://files.pine64.org/doc/PinePhone/PinePhone%20Keyboard%20Schematic%20V1.0-20211009.pdf PinePhone Keyboard Schematic ver 1.0 20211009]<br />
<br />
* Datasheet:<br />
** [https://files.pine64.org/doc/datasheet/pinephone/EM85F684A.pdf PEM85F684A USB Microcontroller Datasheet]<br />
** [https://files.pine64.org/doc/datasheet/pinephone/IP5209.pdf IP5209 Power Bank SOC Datasheet]<br />
** [https://files.pine64.org/doc/datasheet/pinephone/txs0104e.pdf TXS0104E 4-Bit Bidirectional Voltage-Level Translator Datasheet]<br />
<br />
* Certifications:<br />
** [https://files.pine64.org/doc/cert/PinePhone%20Keyboard%20FCC%20Certificate-S21111804102001.pdf PinePhone Keyboard FCC Certificate]<br />
** [https://files.pine64.org/doc/cert/PinePhone%20Keyboard%20CE%20Certificate-S21111804101001.pdf PinePhone Keyboard CE RED Certificate]<br />
<br />
== External links ==<br />
* [https://www.pine64.org/2022/01/11/pinephone-pro-explorer-edition-pre-orders-open-january-11/ Pre-order announcement]<br />
* FAQ of the developer megous: https://xnux.eu/pinephone-keyboard/faq.html</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_(Pro)_Keyboard&diff=12501PinePhone (Pro) Keyboard2022-02-12T07:07:20Z<p>Silver: /* Notes */ Added some additional information about disabling the on screen keyboard</p>
<hr />
<div>[[File:PP_KB_Front-1024x576.jpg|400px|thumb|right|Picture of the PinePhone (Pro) Keyboard]]<br />
<br />
The '''PinePhone (Pro) Keyboard Case''' is a case compatible with the [[PinePhone]] and [[PinePhone Pro]], adding a keyboard functionality to the phone. It features a clam-shell design and uses the pogo pins located on the smartphone’s midsection and attaches by replacing the default back cover. This add-on effectively turns the PinePhone (Pro) into a PDA with an in-built LTE modem.<br />
<br />
== Getting started ==<br />
[[File:Ppkb_description.png|thumb|upright=1.2|<br />
① Contact pads<br><br />
② Battery switch<br><br />
③ USB-C connector]]<br />
<br />
The keyboard case works with both the PinePhone and PinePhone Pro and features a clam-shell design. It uses pogo pins located on the phone’s midsection and attaches by replacing the default back cover. When folded, the phone’s screen and the keyboard rest securely against each other. The hinge features a 180° design, which not only allows for two-hand typing on a surface but also for comfortable thumb-typing when fully extended. The etched keycaps can be easily relocated for alternate layouts such as AZERTY or QWERTZ. The keyboard case runs an [https://xff.cz/git/pinephone-keyboard/ open firmware], which means that anyone with the know-how can alter existing functions or add new ones. The bottom (keyboard) and top (phone) sections of the assembly are well-balanced thanks to the large, 6000mAh, internal battery capable of charging the PinePhone (Pro) during operation. The internal battery effectively triples the phone’s battery life. The internal keyboard battery can be manually toggled on/off and the keyboard’s battery charge level can be read in the supported OSes; the keyboard remains functional with the battery fully depleted.<br />
<br />
You do not lose access to the PinePhone (Pro)’s USB-C port, speaker, microphone, or any external features, such as volume and lock buttons, with the keyboard attached. There is also a cut-out for the camera, torch, and headphone jack. The USB-C port on the keyboard is capable of powering both the keyboard and PinePhone (Pro) simultaneously. This means that you can plug in a USB mouse, a USB-C dongle, or some other peripheral while the phone and keyboard’s internal battery charge ('''warning:''' it is highly advised to read the [[PinePhone (Pro) Keyboard#Safety|safety]] section prior doing this). Please keep in mind that the keyboard case transforms the PinePhone (Pro) into a PDA, which means that taking calls will likely prove awkward without a wired or wireless headset connected.<br />
<br />
=== Mounting the keyboard ===<br />
Power off your PinePhone and remove the back case. To remove the back case of the PinePhone use your fingernail or another soft object to pry up the back case. A notch to easily remove the cover is located at the bottom left of the PinePhone with the backcover facing the user. <br />
<br />
Open and place the keyboard flat on a hard surface with the hinge fully extended. Proceed to insert the PinePhone into the keyboard at an angle of approx. 15 degrees. Make sure that the PinePhone’s pogo pins and the corresponding pads ① on the keyboard are aligned. The leading edge with volume and power buttons should make contact first. Firmly press the PinePhone into place. Multiple clicks should be heard as the two snap into place. Pay special attention to the plastic pin below the camera hole. Firmly push from the rear, below the camera hole, to click it into position. Failing to do so may cause an insufficient pin contact and prevent the case from charging the phone.<br />
<br />
The PinePhone can be removed from the keyboard easily using a notch similar to the one found on the back case. The notch is located at the bottom of the leading edge with the power and volume buttons.<br />
<br />
=== Operation ===<br />
The keyboard will function automatically once a PinePhone running a compatible operating system is mounted. For alterations to physical layout and firmware see the relevant sections respectively.<br />
<br />
The keyboard features an in-built 6000mAh battery. The battery can be turned ON/OFF using the button on the right leading edge of the keyboard ②. A short button press activates the internal battery while a long (15 seconds) press deactivates it. Compatible operating systems display both the PinePhone’s and keyboard’s battery status.<br />
<br />
You should charge the PinePhone and the keyboard <u>only</u> using the USB-C ③ port on the keyboard. The keyboard’s USB-C port cannot be used for peripherals. The PinePhone’s USB-C port remains operational when mounted in the keyboard and can be used for data and peripherals.<br />
<br />
=== Troubleshooting ===<br />
There are multiple possible hardware issues users could face. It is recommend to check the following most common hardware issues and their solutions and workarounds.<br />
<br />
==== Pogo pins not making proper contact ====<br />
Under certain scenarios the keyboard's contacts are not making proper contact with the pogo pins of the phone. To address the issue:<br />
<br />
* Power down the phone!<br />
* Apply '''slight''' pressure in the upper mid of the PinePhone's backside until the plastic holder pin towards the upper middle of the keyboard cover, until an audible click can be heard.<br />
* Make sure the contacts and pogo pins are clean and the pogo pins can be slightly pressed individually.<br />
* If the above does not work, a shim under the keyboard's contacts might be required, as explained [https://xnux.eu/pinephone-keyboard/faq.html#ts FAQ troubleshooting section]. See also this [https://freiburg.social/system/media_attachments/files/107/684/243/421/870/279/original/a5e9c68ff3510ec8.jpeg photo of where to place the shim]<br />
<br />
==== Top row is less responsive ====<br />
The keys of the top row may be less responsive. The issue can be worked around by adding inserts to the underside of the top row key caps to decrease the travel distance. More details regarding the workaround can be found in the corresponding section of the FAQ page of the developer megi: https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
==== Software issues ====<br />
For any software issue please see the [[PinePhone (Pro) Keyboard#Software support|Software support section]] and the [[PinePhone (Pro) Keyboard#Frequently asked questions|FAQ section]].<br />
<br />
== Safety ==<br />
{{Under construction}}<br />
<br />
{{warning|1=Do NOT plug any power source into the phone USB-C port while the keyboard is attached. Doing so may result in damage or loss of the keyboard charging functionality.}}<br />
{{warning|1=Do NOT lube the keyboard with GPL 205G0 switch grease. It can cause problems with the key responsiveness and tactility.}}<br />
{{hint|Only use mild isopropyl alcohol when wiping down the clamshell of the device. Stronger solutions may partially strip the coatings.}}<br />
<br />
== Software support ==<br />
<br />
=== Kernel-space driver ===<br />
<br />
Kernel driver implementation from Samuel Holland: ip5xxx_power and kb151 https://github.com/smaeul/linux/commits/wip/pp-keyboard<br />
<br />
=== User-space driver ===<br />
The user-space driver is available [https://xff.cz/git/pinephone-keyboard/ here]. Use git to clone the repository. You're going to need sdcc 4.1+ installed to build it, so use your package manager to install that first. Next you'll cd into the directory you cloned pinephone-keyboard and use the command "make" to build. After the build is completed, cd into the build directory and you'll notice several new files starting with ppkb-. To use your keyboard case, you'll want to run the following command: <code>sudo ./ppkb-i2c-inputd</code> <!-- this isn't running as a daemon, if anyone knows how to make it do so please edit that info in! --> Open something you can type into like a new terminal window or text editor and you should now be able to use the keyboard case! <br />
<br />
=== Notes ===<br />
Virtual keyboards such as <i>squeekboard</i> are opening whenever a text field is selected.<br />
<br />
To disable this behavior under GNU/Linux running Phosh, you can run the following: <br />
<br />
To disable the virtual keyboard: <code>gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled false</code><br />
<br />
To enable the virtual keyboard: <code>gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled true</code><br />
<br />
The virtual keyboard needs to be activated before removing the keyboard case again, however this setting observed not to persist between reboots in pmos but be warned regardless that you do need a keyboard of some kind to log in.<br />
<br />
A setting to disable the keyboard can be found in Settings -> Accessibility -> Screen Keyboard according to https://forum.pine64.org/showthread.php?tid=15789&pid=105152<br />
<br />
The keyboard can be disabled in plasma via widget https://forum.pine64.org/showthread.php?tid=14789&pid=105077#pid105077<br />
<br />
In sxmo keyboard disable is not needed, keyboard only shown when power pressed (X11 pmos and according to old documentation) or vol down pressed (wayland pmos, new default?)<br />
<br />
== Keyboard layout ==<br />
The keyboard features a default layout (pictured below) created and agreed upon by the community. The keyboard layout can be altered using software as well as by physically repositioning keycaps. All keycaps, with the <u>exception</u> of space and return keys, can be easily and safely relocated for alternative layouts corresponding to software settings.<br />
<br />
<gallery mode="nolines" widths="500px" heights="400px"><br />
Image:Ppkb_layout2.png|The keyboard layout how the keys were originally intended<br />
</gallery><br />
<br />
== Keyboard firmware ==<br />
PinePhone’s keyboard firmware was developed independently by Ondřej Jirman as a free-of-charge contribution to PINE64. The firmware source code is freely and publicly available and you can modify it, and the supporting utilities, using common FOSS tools. <br />
<br />
=== Firmware and supporting utilities ===<br />
The design of the firmware allows the keys, modifier keys, and their combinations to be handled in virtually unlimited ways, without a need to flash a customized version of the firmware. Mapping of keys is defined at runtime, using the supporting utilities, and is not hardcoded in the firmware. Different keyboard layouts can be loaded dynamically to support various use cases.<br />
<br />
The repository that contains the source code of the firmware, supporting utilities and associated documentation is located at https://xnux.eu/pinephone-keyboard/.<br />
<br />
You are welcome to contribute patches and improvements to the firmware and the supporting utilities. A summary of firmware development history is available at https://xnux.eu/log/ alongside other development updates from the firmware author.<br />
<br />
Much time and effort went into the development of this firmware. If you wish to send a token of appreciation or support the development efforts in any way, please consider making a donation to the author via one of the methods listed at the bottom of this web page: https://xnux.eu/contribute.html.<br />
<br />
=== Firmware License ===<br />
<br />
<blockquote>Copyright (C) 2021 Ondřej Jirman <megi@xff.cz><br />
<br />
This program is free software: you can redistribute it and/or modify<br />
it under the terms of the GNU General Public License as published by<br />
the Free Software Foundation, with either version 3 of the License or<br />
(at your discretion) any later version.<br />
<br />
This program is distributed in the hope that it will be useful,<br />
but WITHOUT ANY WARRANTY; without even the implied warranty of<br />
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. <br />
See GNU General Public License for more details.<br />
<br />
GNU General Public License http://www.gnu.org/licenses/</blockquote><br />
<br />
== Hardware ==<br />
Key hardware specifications:<br />
* Dimensions (closed): 161 x 95 x 21.5mm<br />
* Weights (without / with PinePhone mounted): ~ 191 / ~391 grams<br />
* Number of keys: 54<br />
* Number of rows: 5<br />
** Keyboard IC: Keyboard IC: EM85F684A 8-bit microcontroller with 256 bytes RAM, 2048/ bytes XRAM; 16kB for user’s own firmware<br />
* Battery capacity: 6000mAh (22.2Wh 3.7V)<br />
* Charger input: 5V, 3A (15W)<br />
** Charging and battery IC chip: IP5209 power management IC with charge indicate controller and boost converter<br />
<br />
== Frequently asked questions ==<br />
{{Under construction}}<br />
<br />
''' The keyboard does not work under OSK-SDL (full-disk encryption UI at boot) '''<br><br />
That is a known bug, see https://gitlab.com/postmarketOS/pmaports/-/issues/1383.<br />
<br />
''' What is the keyboard driver situation? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#drivers<br />
<br />
''' Are keyboard drivers included in my distribution? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#distros<br />
<br />
''' What's the status of the existing software for the keyboard? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#sw-status<br />
<br />
''' My keyboard doesn't work (well)! '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#faq-ts<br />
<br />
''' How does charging work? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#charging<br />
<br />
''' What charger is best for the keyboard? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#chargers<br />
<br />
''' How safe is the charger circuit in the keyboard? '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#safety<br />
<br />
''' Keyboard doesn't react to any key presses '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Keyboard works but top row of keys is less responsive '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Phone is not charging from the keyboard '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Phone is charging slowly from the keyboard battery '''<br><br />
See https://xnux.eu/pinephone-keyboard/faq.html#ts<br />
<br />
''' Can you open the keyboard and add extra functionality? '''<br><br />
It is possible to do so, however the production units can be extremely difficult to open. Do not attempt to open the keyboard if you do not want to risk cosmetic damage (scaring and scratching of the plastic).<br />
<br />
== Documents ==<br />
<br />
* [https://files.pine64.org/doc/PinePhone/USER%20MANUAL-KEYBOARD-V2-EN-DE-FR-ES.pdf PinePhone Keyboard 4 language user manual ver 2.0 in PDF format]<br />
* [https://files.pine64.org/doc/PinePhone/USER%20MANUAL-KEYBOARD-V2-EN-DE-FR-ES.odt PinePhone Keyboard 4 language user manual ver 2.0 in ODT format]<br />
<br />
== Schematics, Datasheet and certifications ==<br />
<br />
* Schematic:<br />
** [https://files.pine64.org/doc/PinePhone/PinePhone%20Keyboard%20Schematic%20V1.0-20211009.pdf PinePhone Keyboard Schematic ver 1.0 20211009]<br />
<br />
* Datasheet:<br />
** [https://files.pine64.org/doc/datasheet/pinephone/EM85F684A.pdf PEM85F684A USB Microcontroller Datasheet]<br />
** [https://files.pine64.org/doc/datasheet/pinephone/IP5209.pdf IP5209 Power Bank SOC Datasheet]<br />
** [https://files.pine64.org/doc/datasheet/pinephone/txs0104e.pdf TXS0104E 4-Bit Bidirectional Voltage-Level Translator Datasheet]<br />
<br />
* Certifications:<br />
** [https://files.pine64.org/doc/cert/PinePhone%20Keyboard%20FCC%20Certificate-S21111804102001.pdf PinePhone Keyboard FCC Certificate]<br />
** [https://files.pine64.org/doc/cert/PinePhone%20Keyboard%20CE%20Certificate-S21111804101001.pdf PinePhone Keyboard CE RED Certificate]<br />
<br />
== External links ==<br />
* [https://www.pine64.org/2022/01/11/pinephone-pro-explorer-edition-pre-orders-open-january-11/ Pre-order announcement]<br />
* FAQ of the developer megous: https://xnux.eu/pinephone-keyboard/faq.html</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_Carrier_Support&diff=12100PinePhone Carrier Support2021-12-23T21:26:03Z<p>Silver: removed mms banner now that chatty and spacebar both support mms</p>
<hr />
<div>{{under construction}}<br />
<br />
This page contains hints on setting up cellular network connectivity for specific carriers.<br />
For more general information, see the carrier support section of [[PinePhone#Modem]]. For the APN settings see [[PinePhone APN Settings]].<br />
<br />
= Check compatibility =<br />
To check if the PinePhone is supported on your carrier:<br />
<br />
Search for your carrier on [https://www.frequencycheck.com/ frequencycheck.com] and compare the carrier's LTE/GSM/WCDMA frequencies to the PinePhone's supported frequencies (listed in the [[File:Quectel_EG25-G_LTE_Standard_Specification_V1.3.pdf]] modem specification sheet).<br />
<br />
It is likely that there will be a few frequencies that your carrier uses which are not supported by the PinePhone. Not all of the carrier's frequencies need to be supported by the PinePhone for it to work - as long as ''most'' of them are supported, you will still get good coverage.<br />
<br />
= Tested and working carriers =<br />
<br />
The following is a list of carriers which has been tested by users and confirmed to be working (excerpt):<br />
<br />
== Asia ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS working || MMS working || Calls working || Data working || Tested OS (with version) and UI<br />
|-<br />
| Japan || SoftBank || Not tested || Unsupported by carrier || No || No || Mobian Phosh, December 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || Yes || Mobian Phosh, January 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || No || Manjaro Plasma Mobile February 2021<br />
|-<br />
| Japan || Docomo || Yes || Not tested || Yes || Yes || Mobian Phosh, February 2021<br />
|-<br />
| India || Vodafone / Vi India || Yes || Not tested || Yes || Yes || DanctNIX (Arch Linux ARM) with Phosh, March 2021<br />
|-<br />
| South Korea || KT || Yes || Not tested || Yes || Yes || Manjaro Phosh, June 2021<br />
|}<br />
<br />
== Africa ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS working || MMS working || Calls working || Data working || Tested OS (with version) and UI<br />
|-<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || TestOS with Phosh, 20201129<br />
|-<br />
|}<br />
<br />
== Europe ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS working || MMS working || Calls working || Data working || Tested OS (with version) and UI<br />
|-<br />
|-<br />
| Ukraine || KyivStar || Yes || Not tested || Yes || Yes || Mobian Phosh(11Nov21)<br />
|-<br />
| Sweden || Telenor SE || Not tested || Not tested || Yes || Not tested || Manjaro Plasma Mobile beta2<br />
|-<br />
| UK || Three || Yes || Not tested || Yes || Yes || Manjaro Plasma Mobile beta2<br />
|-<br />
| UK || Vodafone || Yes || Not tested || Yes || Yes || ALARM & pmOS (Phosh?), modem FW latest - 26 Feb 21<br />
|-<br />
| UK || Sky Mobile || Yes || Not tested || Yes || Yes || ArchLinux Phosh (20210908 image, fully updated) - 3 October 2021<br />
|-<br />
| France || Orange || Yes || Not tested || Yes || Yes || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
| France || SFR || Yes || Not tested || Yes || Yes || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
| France || Free || Yes || Not tested || Yes || Not tested || ArchLinux - 30 July 2021<br />
|-<br />
| Czech Republic || O2 || Yes (only on 2G) || Not tested || Yes || Yes || Mobian Phosh (20210517 image up to date) - 2 June 2021<br />
|-<br />
| Germany || Congstar || Yes || Not tested || Yes || Yes (IPv4 & IPv6) || Mobian (Megi's kernel 5.13.0-rc4, apt up-to-date) with Phosh, 2021-06-07<br />
|-<br />
| Germany || E-Plus || Yes (sending only 2G) || Not tested || Yes || Yes || Manjaro Phosh and postmarketOS, 2021-10-15<br />
|-<br />
| Germany || Telekom || Yes || Not tested || Yes || Not tested || Mobian Phosh (5.10-sunxi64), 2021-07-28<br />
|-<br />
| Germany || O2 / Telefonica || Yes || Not tested || Yes || Not tested || KPlasma<br />
|-<br />
| Hungary || Telekom || Yes || Not tested || Yes || Yes (IPv4) || Manjaro Phosh Beta 12, 2021-07-30<br />
|-<br />
| Hungary || Telenor || Yes || Not tested || Yes || Yes || Mobian-Phosh-20210517, 2021-09-24<br />
|-<br />
| Denmark || CBB || Yes || Not tested || Yes || Yes || Manjaro Plasma Mobile Beta 5, 2021-06-30<br />
|-<br />
| Belgium || Telenet || Yes || Not tested || Yes || Yes || postmarketOS v20.05, v21.03, v21.06 and edge, 2021-08-15<br />
|-<br />
| Belgium || CARREFOUR || Yes || Not tested || Yes || Yes || postmarketOS v20.05, v21.03, v21.06 and edge, 2021-08-15<br />
|-<br />
| Poland || Play || Yes || Not tested || Yes || Yes || Manjaro Phosh Beta 18, 2021-11-14<br />
|}<br />
<br />
== North America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS working || MMS working || Calls working || Data working || Tested OS (with version) and UI<br />
|-<br />
|-<br />
| USA || T-Mobile || Yes || No || Yes || Yes || <br />
* Arch Linux Arm 2020/11/29 <br />
* Mobian - Phosh <br />
* Manjaro - KDE Plasma Mobile<br />
|-<br />
| USA || MetroPCS (T-Mobile) || Yes || No || Yes || Yes || <br />
*Arch Linux Arm (Phosh,SXMO) 2021/04/29 <br />
*Manjaro - Phosh 2021/04/29 <br />
*Mobian - Phosh 2021/3/20<br />
|-<br />
| USA || T-Mobile || Yes - buggy || No || Yes - buggy || Yes - buggy || <br />
*Manjaro - Plasma Dev 2020/11/21 <br />
*Ubuntu Touch - 2020/11/26 <br />
*KDE Neon 2020/11/02<br />
|-<br />
| USA || Mint Mobile (T-Mobile) || Yes || Not tested || Yes || Yes || <br />
*Mobian - Phosh 2021/3/14<br />
*postMarketOS - Phosh, Sxmo, Plasma Mobile 2021/5/26<br />
*Ubuntu Touch 2021/5/24<br />
|-<br />
| USA || Tello (T-Mobile) || Yes || No || Yes || Yes || <br />
*postMarketOS - Phosh 2021/8/15<br />
|-<br />
| USA || TracFone (T-Mobile) || Yes || Not tested || Yes || Yes || <br />
*Arch - Phosh 2021-10-06<br />
|-<br />
| USA || Verizon || Yes || Not tested || Yes || Yes || <br />
*Mobian - Phosh 2021/3/1<br />
|-<br />
| USA || Verizon || No || No || No || No ||<br />
*Ubuntu Touch 2021/5/24 (You can occasionally get the settings to work with Verizon, but it seems like the settings automatically changes the carrier to the wrong one after a few minutes) <br />
|-<br />
| USA || Verizon || Not tested || Not tested || Yes || Not via gui || <br />
*Manjaro - KDE Plasma Mobile 2021/5/10 <br />
|-<br />
| USA || Verizon || Yes || Not tested || Yes || Not via gui || <br />
*Manjaro - Phosh 2021/5/31 <br />
|-<br />
| USA || Verizon || Yes || Not tested || Yes || Yes || <br />
*postmarketOS - Phosh 2021/5/31 <br />
|-<br />
| USA || Verizon || Yes || Not tested || Yes || Yes || <br />
*Arch - Phosh 2021/5/31 <br />
|-<br />
| Canada || Freedom || Yes || Not tested || Yes || Yes || <br />
*Arch Pinephone - Phosh (APN: internet.windmobile.ca), 2021/4/25 <br />
|-<br />
| Canada || SpeakOut || Yes || Not tested || Yes || Not tested || <br />
*Mobian - Phosh 2021/11/18<br />
|-<br />
| USA || FaithWireless (AT&T) || Yes || No || Yes || Yes || <br />
*Arch Linux Arm - Phosh 2021/04/29 (version 0.10.1-1, see the [[PinePhone_Carrier_Support#AT.26T|AT&T issues]] below.)<br />
|-<br />
| USA || Consumer Cellular (AT&T) || Yes || No || Yes || Yes || <br />
*Manjaro - Phosh 2021/06/26<br />
|-<br />
| USA || Google Fi (T-Mobile) || Yes || No || Yes || Yes || <br />
*Arch Linux Arm - Phosh 0.10.2 2021/05/29<br />
|-<br />
| Mexico || Telcel || Yes || Not tested || Yes || Yes ||<br />
*PostmarketOS - sxmo edge 2021/09/09<br />
|-<br />
|}<br />
<br />
== South America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS working || MMS working || Calls working || Data working || Tested OS (with version) and UI<br />
|-<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || TestOS with Phosh, 20201129<br />
|-<br />
|}<br />
<br />
== Australia / Oceania ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS working || MMS working || Calls working || Data working || Tested OS (with version) and UI<br />
|-<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || TestOS with Phosh, 20201129<br />
|-<br />
|}<br />
<br />
== Middle East ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS working || MMS working || Calls working || Data working || Tested OS (with version) and UI<br />
|-<br />
|-<br />
| Israel|| Cellcom prepay|| receive+notify|| NA || ring+ notify || NA || on PmOS Sxmo May 14 2021.<br />
|-<br />
<br />
|-<br />
| Israel|| Golan TC || receive+notify|| NA || ring+ notify || NA || on PmOS Sxmo May 14 2021.<br />
|-<br />
|-<br />
| Israel|| Partner prepay || receive+notify|| NA || ring+ notify || NA || on PmOS Sxmo May 14 2021.<br />
|-<br />
|-<br />
| Israel|| Pelephone prepay|| receive+notify|| NA || ring+ notify || NA || on PmOS Sxmo May 14 2021.<br />
|-<br />
|-<br />
| Israel|| Hot prepay|| receive+notify|| NA || ring+ notify || NA || on PmOS Sxmo May 14 2021.<br />
|-<br />
|-<br />
| Israel|| 019 prepay|| No || NA ||Bars only || NA || on PmOS Sxmo May 14 2021.<br />
|-<br />
<br />
<br />
<br />
<br />
<br />
|}<br />
<br />
= Special carrier notes =<br />
<br />
{{Warning|This section contains providers which do not work or require special settings or actions to work.}}<br />
<br />
Some carriers might support only certain frequencies or might require certain settings in Ofono or ModemManager. The following is a list of collected notes for carriers regarding special settings, hints or information:<br />
<br />
== USA ==<br />
=== AT&T ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page], AT&T's primary bands are 12 and 17 - 700ac and 700 MHz respectively. The PinePhone seems to work out-of-the-box with AT&T. If you transfer a SIM card from another phone you were using with AT&T, you need to activate the PinePhone through [https://www.att.com/buy/wireless/byod/byod AT&T's website]. Calls and SMS messages work. VoLTE is as yet untested.<br />
<br />
However, it is likely AT&T will drop support with their network upgrade in the near future like their child company Cricket Wireless already has. [https://www.att.com/ecms/dam/att/consumer/help/pdf/Devices-Working-on-ATT-Network.pdf This page] lists their supported devices for their new network.<br />
<br />
=== Consumer Cellular ===<br />
<br />
Consumer Cellular is a MVNO that uses both AT&T and T-Mobile networks. On the AT&T network LTE data works without special configuration. If you transfer a SIM card from another phone to the PinePhone, you may need to contact customer support in order for them to register the IMEI association to the correct hardware; in one case it was first incorrectly identified as a Samsung Google Nexus Prime before later being correctly identified by the modem model Quectel EG25-G. Customer support also explicitly enabled VoLTE on the device. After VoLTE instructions on this site were followed and APN instructions on the Consumer Cellular site were followed, VoLTE was confirmed working.<br />
<br />
=== Cricket Wireless ===<br />
Cricket wireless is a MVNO that uses AT&T's network. VoLTE was fully supported, but the PinePhone is no longer considered a compatible device in the US by the carrier (as of March 2021).<br />
<br />
=== SimpleMobile ===<br />
SimpleMobile is a T-Mobile prepaid MVNO operating in the United States. 4G LTE, VoLTE, data, and SMS all work on the PinePhone after activation. Activation can be done online without extra software or assistance, go to https://www.simplemobile.com/activation/byopcollectsim and make sure you have your SIM card and IMEI ready.<br />
<br />
=== Sprint ===<br />
Sprint is currently not supported due to unknown reasons. Any input regarding this issue is highly appreciated.<br />
<br />
=== T-Mobile ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
T-Mobile's primary frequency band for the United States is 12 (700ac MHz).<br />
<br />
T-Mobile's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/t-mobile-united-states this page].<br />
<br />
While the PinePhone's modem does support all LTE bands that T-Mobile uses in the US (And is one of the best choices for band support with the PinePhone's modem in the US), VoLTE is still listed as "Under development" by the modem manufacturer. T-Mobile's system also does not list the PinePhone as a compatible device due to this lack of official VoLTE support. The modem is capable of working on T-Mobile with VoLTE support enabled.<br />
<br />
=== Verizon ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
Verizon's primary frequency band for the United States is 13 (700 MHz). Verizon's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/verizon-wireless-united-states this page]. According to the same page, Verizon might restrict their network to only approved devices.<br />
<br />
Some users reported that they were able to activate their Verizon SIM by using an Verizon-approved burner phone and then inserting the SIM into the PinePhone.<br />
<br />
=== Google Fi ===<br />
Only T-Mobile service works currently, not US Cellular or Sprint.<br />
The APN is h2g2.<br />
Information from [https://forum.pine64.org/showthread.php?tid=11675&page=7 the forum].<br />
<br />
Bear in mind that initial activation of the SIM card is not possible without an Android phone running Google Apps. <br />
<br />
It should also be noted that Google uses a non-standard MMS implementation that is unlikely to be supported on the PinePhone at any point.<br />
<br />
== Europe ==<br />
=== Telekom Germany ===<br />
With low signal, there may be loud interference noise audible in calls on the receiving end. It has not yet been tested whether or not this problem is carrier specific. An easy fix is extending the modem antenna with aluminum foil (or similar) inside the back cover of the phone.<br />
<br />
= Known issues =<br />
Known issues:<br />
* The [https://www.frequencycheck.com/models FrequencyCheck model page] does not list either Pine64 or the PinePhone.<br />
* T-Mobile's system does not list the PinePhone as a compatible device due to the lack of official VoLTE support from the manufacturer, despite the fact that it does work.<br />
* MMS doesn't currently work in any distribution on the PinePhone by default. This means images and group chats will not work in text messages.<br />
* Some providers may allow only certain known devices identified by their [https://en.wikipedia.org/wiki/Type_Allocation_Code Type Allocation Code].<br />
<br />
= MMS workarounds =<br />
These scripts allow partial MMS support on a [[PinePhone]] in distributions without working MMS support:<br />
<br />
* JMMS: [https://git.sr.ht/~amindfv/jmms]<br />
* silvermms: [https://gitlab.com/5ilver/silvermms]<br />
* MMS via Matrix with mmmpuppet: [[PinePhone MMS with Matrix]]<br />
<br />
There is a Haskel MMS client. MMS can also be manually composed with mmsd on the command line.<br />
<br />
= Resources =<br />
* IMEI - [https://en.wikipedia.org/wiki/International_Mobile_Equipment_Identity International Mobile Equipment Identity]<br />
<br />
<br />
[[Category:PinePhone]]</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11560PinePhone MMS with Matrix2021-10-01T23:35:22Z<p>Silver: /* Done */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully (meaning pictures and group messages) working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. https://gitlab.com/untidylamp/mmmpuppet is the bridge used here<br />
<br />
Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This method works with a local-to-the-pinephone matrix server but you could instead use a public one on the internet. Free accounts on matrix.org should work fine for example. Sleep may need to be disabled for non-local servers or the bridge can get stuck.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
</pre><br />
<br />
== Add new matrix users ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. You need to add a new item named login to the gnome keyring manually to fix it. See: https://wiki.mobian-project.org/doku.php?id=fractal<br />
<br />
Basically apt install seahorse, open "passwords and keys" in the app drawer, click new (plus), select password keyring, and name it "login" (all lower no quotes). Then autologin will work as it should.<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. You can start a new conversation by creating a new room, setting the topic with phone numbers of participants, and then inviting the mm user. See the mmmpuppet readme for examples.<br />
<br />
=Other clients=<br />
<br />
quaternion also seems to work but has clunky UI issues. Might work better with scaling</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11559PinePhone MMS with Matrix2021-10-01T23:13:28Z<p>Silver: /* Done */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully (meaning pictures and group messages) working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. https://gitlab.com/untidylamp/mmmpuppet is the bridge used here<br />
<br />
Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This method works with a local-to-the-pinephone matrix server but you could instead use a public one on the internet. Free accounts on matrix.org should work fine for example. Sleep may need to be disabled for non-local servers or the bridge can get stuck.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
</pre><br />
<br />
== Add new matrix users ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. You need to add a new item named login to the gnome keyring manually to fix it. See: https://wiki.mobian-project.org/doku.php?id=fractal<br />
<br />
Basically apt install seahorse, open "passwords and keys" in the app drawer, click new (plus), select password keyring, and name it "login" (all lower no quotes). Then autologin will work as it should.<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.<br />
<br />
=Other clients=<br />
<br />
quaternion also seems to work but has clunky UI issues. Might work better with scaling</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11553PinePhone MMS with Matrix2021-10-01T05:03:16Z<p>Silver: /* Launch fractal */ note about an autologin fix</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully (meaning pictures and group messages) working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. https://gitlab.com/untidylamp/mmmpuppet is the bridge used here<br />
<br />
Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This method works with a local-to-the-pinephone matrix server but you could instead use a public one on the internet. Free accounts on matrix.org should work fine for example. Sleep may need to be disabled for non-local servers or the bridge can get stuck.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
</pre><br />
<br />
== Add new matrix users ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. You need to add a new item named login to the gnome keyring manually to fix it. See: https://wiki.mobian-project.org/doku.php?id=fractal<br />
<br />
Basically apt install seahorse, open "passwords and keys" in the app drawer, click new (plus), select password keyring, and name it "login" (all lower no quotes). Then autologin will work as it should.<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11549PinePhone MMS with Matrix2021-09-29T18:04:57Z<p>Silver: /* and add a new user. */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully (meaning pictures and group messages) working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. https://gitlab.com/untidylamp/mmmpuppet is the bridge used here<br />
<br />
Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This method works with a local-to-the-pinephone matrix server but you could instead use a public one on the internet. Free accounts on matrix.org should work fine for example. Sleep may need to be disabled for non-local servers or the bridge can get stuck.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
</pre><br />
<br />
== Add new matrix users ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. I think there was another package for a keyring or something that enables it?<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11548PinePhone MMS with Matrix2021-09-29T18:04:32Z<p>Silver: /* mobian */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully (meaning pictures and group messages) working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. https://gitlab.com/untidylamp/mmmpuppet is the bridge used here<br />
<br />
Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This method works with a local-to-the-pinephone matrix server but you could instead use a public one on the internet. Free accounts on matrix.org should work fine for example. Sleep may need to be disabled for non-local servers or the bridge can get stuck.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. I think there was another package for a keyring or something that enables it?<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11532PinePhone MMS with Matrix2021-09-29T06:39:50Z<p>Silver: </p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully (meaning pictures and group messages) working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. https://gitlab.com/untidylamp/mmmpuppet is the bridge used here<br />
<br />
Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This method works with a local-to-the-pinephone matrix server but you could instead use a public one on the internet. Free accounts on matrix.org should work fine for example. Sleep may need to be disabled for non-local servers or the bridge can get stuck.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. I think there was another package for a keyring or something that enables it?<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11531PinePhone MMS with Matrix2021-09-29T06:39:14Z<p>Silver: </p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully (meaning pictures and group messages) working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. https://gitlab.com/untidylamp/mmmpuppet is the bridge used here<br />
<br />
Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This works method with a local-to-the-pinephone matrix server but you could instead use a public one on the internet. Free accounts on matrix.org should work fine for example. Sleep may need to be disabled for non-local servers or the bridge can get stuck.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. I think there was another package for a keyring or something that enables it?<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11530PinePhone MMS with Matrix2021-09-29T06:32:05Z<p>Silver: /* remove chatty */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Don't forget to enable data=<br />
<br />
You can get sms but not mms with mobile data off<br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. I think there was another package for a keyring or something that enables it?<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11529PinePhone MMS with Matrix2021-09-29T05:50:21Z<p>Silver: /* Done */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=remove chatty=<br />
for arch do pacman stuff to remove chatty<br />
<br />
mobian<br />
<pre><br />
apt remove chatty<br />
</pre><br />
<br />
=Launch fractal=<br />
<br />
Log in with this homeserver<br />
<br />
<pre>http://localhost:8008</pre><br />
<br />
username <pre>pp</pre> and password <pre>pp</pre><br />
<br />
Logins are not saved. I think there was another package for a keyring or something that enables it?<br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11528PinePhone MMS with Matrix2021-09-29T05:47:03Z<p>Silver: /* Configure MMS bridge */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets (It will say it has done this and exit on first run)<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11527PinePhone MMS with Matrix2021-09-29T05:45:45Z<p>Silver: /* Install MMSD */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Set up MMSD=<br />
<br />
==from git (historical, no longer needed, mmsdtng commonly packaged)==<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
After starting mmsdtng the first time it should generate a config. Edit the following 3 options:<br />
<pre><br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Restart MMSD ModemManager service==<br />
<br />
<pre><br />
systemctl restart mmsdtng<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11526PinePhone MMS with Matrix2021-09-29T05:39:35Z<p>Silver: /* Set up Matrix Synapse on localhost */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
==Arch==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==mobian==<br />
<pre><br />
cd /etc/matrix-synapse/<br />
sudo rm homeserver.*<br />
sudo python3 -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
sudo service matrix-synapse start<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008<br />
</pre><br />
<br />
==and add a new user. ==<br />
in /etc/synapse/ (arch) or /etc/matrix-synapse/ (mobian)<br />
<br />
<pre><br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mm<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Install MMSD=<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11525PinePhone MMS with Matrix2021-09-29T05:35:48Z<p>Silver: /* Mobian */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
<pre>sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git</pre><br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==and add a new user. ==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be bot<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Install MMSD=<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=11524PinePhone MMS with Matrix2021-09-29T05:35:25Z<p>Silver: /* Mobian */</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
Flash a fresh mobian nightly (Tested September 28 2021) and install the following:<br />
<br />
sudo apt install matrix-synapse fractal mmsd-tng python3-matrix-nio python3-vobject python3-aiofiles git<br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==and add a new user. ==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be bot<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Install MMSD=<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10265PinePhone MMS with Matrix2021-05-08T01:24:57Z<p>Silver: Adding a screenshot to demonstrate how it works</p>
<hr />
<div>[[File:Pinephonematrixfractalmmsscreenshot.jpg|thumb|upright=1.2|Screenshot of fractal displaying an MMS conversation]]<br />
<br />
The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==and add a new user. ==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be bot<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Install MMSD=<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=File:Pinephonematrixfractalmmsscreenshot.jpg&diff=10264File:Pinephonematrixfractalmmsscreenshot.jpg2021-05-08T01:19:04Z<p>Silver: Screenshot of fractal displaying a conversation through the mmmpuppet matrix to modemmanager and mmsd bridge</p>
<hr />
<div>== Summary ==<br />
Screenshot of fractal displaying a conversation through the mmmpuppet matrix to modemmanager and mmsd bridge</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10199PinePhone MMS with Matrix2021-05-02T23:49:48Z<p>Silver: </p>
<hr />
<div>The one known way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using a matrix client to interact with them. This allows fully working group and image messaging.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
This works with either a local-to-the-pinephone matrix server, or a public one on the internet. Free accounts on matrix.org should work fine for example.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==and add a new user. ==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be bot<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Install MMSD=<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10198PinePhone MMS with Matrix2021-05-02T23:47:53Z<p>Silver: Updated matrix server service info for mobian.</p>
<hr />
<div>One way to get MMS fully working is by relaying all SMS and MMS to a matrix server and using the fractal matrix client to interact with them.<br />
<br />
On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself, so resize your images. An easy way might be to take a screenshot of your image viewer and send that image instead.<br />
<br />
This is being tested on Mobian and Arch with Phosh.<br />
<br />
On Arch it works for SMS, but images don't go through in or out. Unresolvable links are sent out with an older mmsd, nothing but an error in the log with a newer mmsd. This is probably a configuration issue.<br />
<br />
Most of this should be cut and pastable. <br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
Start the service<br />
<br />
<pre><br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
</pre><br />
<br />
==Mobian==<br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/matrix-synapse.service<br />
</pre><br />
<br />
<pre><br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart= python3 -m synapse.app.homeserver --config-path=/etc/matrix/homeserver.yaml<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
Start the service<br />
<pre><br />
systemctl enable matrix-synapse --user<br />
systemctl start matrix-synapse --user<br />
<br />
</pre><br />
<br />
==and add a new user. ==<br />
<br />
<pre><br />
cd /etc/synapse/<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pp<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be bot<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pp and password pp<br />
<br />
=Install MMSD=<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mm:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mm"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pp:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though. Using another matrix client, perhaps a command line one, would work.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10194PinePhone MMS with Matrix2021-05-02T21:57:02Z<p>Silver: /* Settings for T-Mobile */</p>
<hr />
<div>This is a possible way to get MMS fully working by relaying SMS to a matrix server with a bridge from MMSD, and using the fractal matrix client to interact with them. Most of this should be cut and pastable. On Mobian, incoming and outgoing MMS works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the PinePhone itself.<br />
<br />
This is being tested on Mobian and Arch with Phosh.<br />
<br />
On Arch matrix-synapse 1.29.0-1, fractal 4.4.0-2 (saving login doesn't work), kop316 mmsd v0.3 -- Works for SMS, but images don't go through in or out. Unresolvable links are sent out, so maybe small images will go?<br />
<br />
On Mobian I'm using matrix-synapse-py3 1.30.0+bionic1 (on a remote VPS server), fractal 4.4.0-2 (and saving the login actually works), kop316 mmsd 0.1-2.2, and images DO go through in and out, with resolvable links out for large images. With matrix_synapse-1.32.2 from pip installed locally images are received but unresolvable links are sent, perhaps this works fine with smaller images though.<br />
<br />
=Install packages=<br />
==Arch==<br />
Start with a nice and up-to-date Danctnix' Arch ARM PinePhone installation, mine is from April 20 2021. SSH into the PinePhone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
==Mobian==<br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
Start the service and add a new user. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pinephone<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mmsbridge<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pinephone and password pinephone<br />
<br />
=Install MMSD=<br />
Grab the git repository and install it:<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for T-Mobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
AutoProcessSMSWAP=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install MMS bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure MMS bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mmsbridge:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mmsbridge"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pinephone:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up MMS bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Needs more testing to find problems. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the MMS bridge can use. The ones the bridge creates work fine though.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_Carrier_Support&diff=10142PinePhone Carrier Support2021-04-27T22:23:59Z<p>Silver: changed link for mms scripts to point at the correct section in this page</p>
<hr />
<div>{{under construction}}<br />
<br />
{{warning|1= MMS currently doesn't work in any distribution on the PinePhone without a [[PinePhone_Carrier_Support#MMS_workarounds|script]]! This means images and group chats will not work in text messages.}}<br />
<br />
This page contains hints on setting up cellular network connectivity for specific carriers.<br />
For more general information, see [[PinePhone#Modem_and_carrier_support|Modem and carrier support]]. For the APN settings see [[PinePhone APN Settings]].<br />
<br />
= Check compatibility =<br />
To check if the PinePhone is supported on your carrier:<br />
<br />
Search for your carrier on [https://www.frequencycheck.com/ frequencycheck.com] and compare the carrier's LTE/GSM/WCDMA frequencies to the PinePhone's supported frequencies (listed in the [https://www.quectel.com/UploadFile/Product/Quectel_EG25-G_LTE_Specification_V1.1.pdf modem specification sheet]).<br />
<br />
It is likely that there will be a few frequencies that your carrier uses which are not supported by the PinePhone. Not all of the carrier's frequencies need to be supported by the PinePhone for it to work - as long as ''most'' of them are supported, you will still get good coverage.<br />
<br />
= Tested and working carriers =<br />
<br />
The following is a list of carriers which has been tested by users and confirmed to be working (excerpt):<br />
<br />
== Asia ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS/Email || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Japan || SoftBank || Not tested || Unsupported by carrier || No || No || ModemManager || Mobian December 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || Yes || ModemManager || Mobian January 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || No || Ofono || Manjaro Plasma Mobile February 2021<br />
|-<br />
| Japan || Docomo || Yes (SMS) || Not tested || Yes || Yes || ModemManager || Mobian February 2021<br />
|-<br />
| India || Vodafone / Vi India || Yes (SMS) || Not tested || Yes || Yes || ModemManager || DanctNIX (Arch Linux ARM) with Phosh, March 2021<br />
|}<br />
<br />
== Africa ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
== Europe ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Sweden || Telenor SE || Not tested || Not tested || Yes || Not tested || ModemManager || Manjaro Plasma Mobile beta2<br />
|-<br />
| UK || Vodafone || Yes || Not tested || Yes || Yes || ModemManager || ALARM & pmOS, modem FW latest - 26 Feb 21<br />
|-<br />
| France || Orange || Yes || Not tested || Yes || Yes || ModemManager || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
| France || SFR || Yes || Not tested || Yes || Yes || ModemManager || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
|}<br />
<br />
== North America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| USA || T-Mobile || Yes || No || Yes || Yes || ModemManager || Arch Linux Arm 2020/11/29, Mobian Phosh, Manjaro KDE Plasma Mobile<br />
|-<br />
| USA || T-Mobile(MetroPCS) || Yes || No || Yes || Yes || ModemManager || Mobian 2021/3/20<br />
|-<br />
| USA || T-Mobile || Yes - buggy || No || Yes - buggy || Yes - buggy || Ofono || Manjaro Plasma Dev 2020/11/21 & Ubuntu Touch 2020/11/26 & KDE NEON 2020/11/02<br />
|-<br />
| USA || Red Pocket || Yes || Not tested || Yes || Not tested || ModemManager || mobian-pinephone-phosh-2020/12/15<br />
|-<br />
| USA || Verizon || Yes || Not tested || Yes || Yes || ModemManager || mobian-pinephone-phosh-2021/3/1<br />
|-<br />
| Canada || Freedom || Yes || Not tested || Yes || Yes || ModemManager || Arch Pinephone Phosh AP: internet.windmobile.ca 2021/4/25 <br />
|-<br />
|}<br />
<br />
== South America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
== Australia / Oceania ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
= Special carrier notes =<br />
Some carriers might support only certain frequencies or might require certain settings in Ofono or ModemManager. The following is a list of collected notes for carriers regarding special settings, hints or information:<br />
<br />
== USA ==<br />
=== AT&T ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page], AT&T's primary bands are 12 and 17 - 700ac and 700 MHz respectively. The PinePhone seems to work out-of-the-box with AT&T. Activating a SIM works. Calls and SMS messages work. VoLTE is as yet untested.<br />
<br />
However, it is likely AT&T will drop support with their network upgrade in the near future like their child company Cricket Wireless already has. [https://www.att.com/ecms/dam/att/consumer/help/pdf/Devices-Working-on-ATT-Network.pdf This page] lists their supported devices for their new network.<br />
<br />
=== Cricket Wireless ===<br />
Cricket wireless is a MVNO that uses AT&T's network. VoLTE was fully supported, but the PinePhone is no longer considered a compatible device in the US by the carrier (as of March 2021).<br />
<br />
=== SimpleMobile ===<br />
SimpleMobile is a T-Mobile prepaid MVNO operating in the United States. 4G LTE, VoLTE, data, and SMS all work on the PinePhone after activation. Activation can be done online without extra software or assistance, go to https://www.simplemobile.com/activation/byopcollectsim and make sure you have your SIM card and IMEI ready.<br />
<br />
=== Sprint ===<br />
Sprint is currently not supported due to unknown reasons. Any input regarding this issue is highly appreciated.<br />
<br />
=== T-Mobile ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
T-Mobile's primary frequency band for the United States is 12 (700ac MHz).<br />
<br />
T-Mobile's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/t-mobile-united-states this page].<br />
<br />
While the PinePhone's modem does support all LTE bands that T-Mobile uses in the US (And is one of the best choices for band support with the PinePhone's modem in the US), VoLTE is still listed as "Under development" by the modem manufacturer. T-Mobile's system also does not list the PinePhone as a compatible device due to this lack of official VoLTE support. The modem is capable of working on T-Mobile with VoLTE support enabled.<br />
<br />
=== Verizon ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
Verizon's primary frequency band for the United States is 13 (700 MHz). Verizon's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/verizon-wireless-united-states this page]. According to the same page, Verizon might restrict their network to only approved devices.<br />
<br />
Some users reported that they were able to activate their Verizon SIM by using an Verizon-approved burner phone and then inserting the SIM into the PinePhone.<br />
<br />
=== Red Pocket ===<br />
Red Pocket works with the pinephone. Calls and sms are working. Data not tested yet.<br />
<br />
== Australia ==<br />
=== Telstra ===<br />
According to [https://www.frequencycheck.com/carriers/telstra-australia this page], Telstra uses the LTE B1, B3 and B28 variants, which are all supported by the EG25-G modem.<br />
<br />
= Known issues =<br />
Known issues:<br />
* The [https://www.frequencycheck.com/models FrequencyCheck model page] does not list either Pine64 or the PinePhone.<br />
* T-Mobile's system does not list the PinePhone as a compatible device due to the lack of official VoLTE support from the manufacturer, despite the fact that it does work.<br />
* MMS doesn't currently work in any distribution on the PinePhone by default. This means images and group chats will not work in text messages.<br />
* Some providers may allow only certain known devices identified by their [https://en.wikipedia.org/wiki/Type_Allocation_Code Type Allocation Code].<br />
<br />
= MMS workarounds =<br />
These scripts allow partial MMS support on a [[PinePhone]]<br />
<br />
JMMS: [https://git.sr.ht/~amindfv/jmms]<br />
<br />
silvermms: [https://gitlab.com/5ilver/silvermms]<br />
<br />
MMS via Matrix with mmmpuppet: [[PinePhone MMS with Matrix]]<br />
<br />
There is a Haskel MMS client, please link if found<br />
<br />
MMS can also be manually composed with mmsd on the command line, please link examples if found<br />
<br />
= Resources =<br />
* IMEI - [https://en.wikipedia.org/wiki/International_Mobile_Equipment_Identity International Mobile Equipment Identity]<br />
<br />
<br />
[[Category:PinePhone]]</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_Carrier_Support&diff=10141PinePhone Carrier Support2021-04-27T22:22:59Z<p>Silver: added mms workarounds section</p>
<hr />
<div>{{under construction}}<br />
<br />
{{warning|1= MMS currently doesn't work in any distribution on the PinePhone without a [[pinephone mms scripts|script]]! This means images and group chats will not work in text messages.}}<br />
<br />
This page contains hints on setting up cellular network connectivity for specific carriers.<br />
For more general information, see [[PinePhone#Modem_and_carrier_support|Modem and carrier support]]. For the APN settings see [[PinePhone APN Settings]].<br />
<br />
= Check compatibility =<br />
To check if the PinePhone is supported on your carrier:<br />
<br />
Search for your carrier on [https://www.frequencycheck.com/ frequencycheck.com] and compare the carrier's LTE/GSM/WCDMA frequencies to the PinePhone's supported frequencies (listed in the [https://www.quectel.com/UploadFile/Product/Quectel_EG25-G_LTE_Specification_V1.1.pdf modem specification sheet]).<br />
<br />
It is likely that there will be a few frequencies that your carrier uses which are not supported by the PinePhone. Not all of the carrier's frequencies need to be supported by the PinePhone for it to work - as long as ''most'' of them are supported, you will still get good coverage.<br />
<br />
= Tested and working carriers =<br />
<br />
The following is a list of carriers which has been tested by users and confirmed to be working (excerpt):<br />
<br />
== Asia ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS/Email || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Japan || SoftBank || Not tested || Unsupported by carrier || No || No || ModemManager || Mobian December 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || Yes || ModemManager || Mobian January 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || No || Ofono || Manjaro Plasma Mobile February 2021<br />
|-<br />
| Japan || Docomo || Yes (SMS) || Not tested || Yes || Yes || ModemManager || Mobian February 2021<br />
|-<br />
| India || Vodafone / Vi India || Yes (SMS) || Not tested || Yes || Yes || ModemManager || DanctNIX (Arch Linux ARM) with Phosh, March 2021<br />
|}<br />
<br />
== Africa ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
== Europe ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Sweden || Telenor SE || Not tested || Not tested || Yes || Not tested || ModemManager || Manjaro Plasma Mobile beta2<br />
|-<br />
| UK || Vodafone || Yes || Not tested || Yes || Yes || ModemManager || ALARM & pmOS, modem FW latest - 26 Feb 21<br />
|-<br />
| France || Orange || Yes || Not tested || Yes || Yes || ModemManager || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
| France || SFR || Yes || Not tested || Yes || Yes || ModemManager || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
|}<br />
<br />
== North America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| USA || T-Mobile || Yes || No || Yes || Yes || ModemManager || Arch Linux Arm 2020/11/29, Mobian Phosh, Manjaro KDE Plasma Mobile<br />
|-<br />
| USA || T-Mobile(MetroPCS) || Yes || No || Yes || Yes || ModemManager || Mobian 2021/3/20<br />
|-<br />
| USA || T-Mobile || Yes - buggy || No || Yes - buggy || Yes - buggy || Ofono || Manjaro Plasma Dev 2020/11/21 & Ubuntu Touch 2020/11/26 & KDE NEON 2020/11/02<br />
|-<br />
| USA || Red Pocket || Yes || Not tested || Yes || Not tested || ModemManager || mobian-pinephone-phosh-2020/12/15<br />
|-<br />
| USA || Verizon || Yes || Not tested || Yes || Yes || ModemManager || mobian-pinephone-phosh-2021/3/1<br />
|-<br />
| Canada || Freedom || Yes || Not tested || Yes || Yes || ModemManager || Arch Pinephone Phosh AP: internet.windmobile.ca 2021/4/25 <br />
|-<br />
|}<br />
<br />
== South America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
== Australia / Oceania ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
= Special carrier notes =<br />
Some carriers might support only certain frequencies or might require certain settings in Ofono or ModemManager. The following is a list of collected notes for carriers regarding special settings, hints or information:<br />
<br />
== USA ==<br />
=== AT&T ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page], AT&T's primary bands are 12 and 17 - 700ac and 700 MHz respectively. The PinePhone seems to work out-of-the-box with AT&T. Activating a SIM works. Calls and SMS messages work. VoLTE is as yet untested.<br />
<br />
However, it is likely AT&T will drop support with their network upgrade in the near future like their child company Cricket Wireless already has. [https://www.att.com/ecms/dam/att/consumer/help/pdf/Devices-Working-on-ATT-Network.pdf This page] lists their supported devices for their new network.<br />
<br />
=== Cricket Wireless ===<br />
Cricket wireless is a MVNO that uses AT&T's network. VoLTE was fully supported, but the PinePhone is no longer considered a compatible device in the US by the carrier (as of March 2021).<br />
<br />
=== SimpleMobile ===<br />
SimpleMobile is a T-Mobile prepaid MVNO operating in the United States. 4G LTE, VoLTE, data, and SMS all work on the PinePhone after activation. Activation can be done online without extra software or assistance, go to https://www.simplemobile.com/activation/byopcollectsim and make sure you have your SIM card and IMEI ready.<br />
<br />
=== Sprint ===<br />
Sprint is currently not supported due to unknown reasons. Any input regarding this issue is highly appreciated.<br />
<br />
=== T-Mobile ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
T-Mobile's primary frequency band for the United States is 12 (700ac MHz).<br />
<br />
T-Mobile's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/t-mobile-united-states this page].<br />
<br />
While the PinePhone's modem does support all LTE bands that T-Mobile uses in the US (And is one of the best choices for band support with the PinePhone's modem in the US), VoLTE is still listed as "Under development" by the modem manufacturer. T-Mobile's system also does not list the PinePhone as a compatible device due to this lack of official VoLTE support. The modem is capable of working on T-Mobile with VoLTE support enabled.<br />
<br />
=== Verizon ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
Verizon's primary frequency band for the United States is 13 (700 MHz). Verizon's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/verizon-wireless-united-states this page]. According to the same page, Verizon might restrict their network to only approved devices.<br />
<br />
Some users reported that they were able to activate their Verizon SIM by using an Verizon-approved burner phone and then inserting the SIM into the PinePhone.<br />
<br />
=== Red Pocket ===<br />
Red Pocket works with the pinephone. Calls and sms are working. Data not tested yet.<br />
<br />
== Australia ==<br />
=== Telstra ===<br />
According to [https://www.frequencycheck.com/carriers/telstra-australia this page], Telstra uses the LTE B1, B3 and B28 variants, which are all supported by the EG25-G modem.<br />
<br />
= Known issues =<br />
Known issues:<br />
* The [https://www.frequencycheck.com/models FrequencyCheck model page] does not list either Pine64 or the PinePhone.<br />
* T-Mobile's system does not list the PinePhone as a compatible device due to the lack of official VoLTE support from the manufacturer, despite the fact that it does work.<br />
* MMS doesn't currently work in any distribution on the PinePhone by default. This means images and group chats will not work in text messages.<br />
* Some providers may allow only certain known devices identified by their [https://en.wikipedia.org/wiki/Type_Allocation_Code Type Allocation Code].<br />
<br />
= MMS workarounds =<br />
These scripts allow partial MMS support on a [[PinePhone]]<br />
<br />
JMMS: [https://git.sr.ht/~amindfv/jmms]<br />
<br />
silvermms: [https://gitlab.com/5ilver/silvermms]<br />
<br />
MMS via Matrix with mmmpuppet: [[PinePhone MMS with Matrix]]<br />
<br />
There is a Haskel MMS client, please link if found<br />
<br />
MMS can also be manually composed with mmsd on the command line, please link examples if found<br />
<br />
= Resources =<br />
* IMEI - [https://en.wikipedia.org/wiki/International_Mobile_Equipment_Identity International Mobile Equipment Identity]<br />
<br />
<br />
[[Category:PinePhone]]</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_Carrier_Support&diff=10135PinePhone Carrier Support2021-04-27T22:10:48Z<p>Silver: Added a link to a page with pinephone mms scripts in the notice bar up top</p>
<hr />
<div>{{under construction}}<br />
<br />
{{warning|1= MMS currently doesn't work in any distribution on the PinePhone without a [[pinephone mms scripts|script]]! This means images and group chats will not work in text messages.}}<br />
<br />
This page contains hints on setting up cellular network connectivity for specific carriers.<br />
For more general information, see [[PinePhone#Modem_and_carrier_support|Modem and carrier support]]. For the APN settings see [[PinePhone APN Settings]].<br />
<br />
= Check compatibility =<br />
To check if the PinePhone is supported on your carrier:<br />
<br />
Search for your carrier on [https://www.frequencycheck.com/ frequencycheck.com] and compare the carrier's LTE/GSM/WCDMA frequencies to the PinePhone's supported frequencies (listed in the [https://www.quectel.com/UploadFile/Product/Quectel_EG25-G_LTE_Specification_V1.1.pdf modem specification sheet]).<br />
<br />
It is likely that there will be a few frequencies that your carrier uses which are not supported by the PinePhone. Not all of the carrier's frequencies need to be supported by the PinePhone for it to work - as long as ''most'' of them are supported, you will still get good coverage.<br />
<br />
= Tested and working carriers =<br />
<br />
The following is a list of carriers which has been tested by users and confirmed to be working (excerpt):<br />
<br />
== Asia ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS/Email || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Japan || SoftBank || Not tested || Unsupported by carrier || No || No || ModemManager || Mobian December 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || Yes || ModemManager || Mobian January 2020<br />
|-<br />
| Japan || Rakuten Mobile || Unsupported by carrier || Unsupported by carrier || Yes || No || Ofono || Manjaro Plasma Mobile February 2021<br />
|-<br />
| Japan || Docomo || Yes (SMS) || Not tested || Yes || Yes || ModemManager || Mobian February 2021<br />
|-<br />
| India || Vodafone / Vi India || Yes (SMS) || Not tested || Yes || Yes || ModemManager || DanctNIX (Arch Linux ARM) with Phosh, March 2021<br />
|}<br />
<br />
== Africa ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
== Europe ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Sweden || Telenor SE || Not tested || Not tested || Yes || Not tested || ModemManager || Manjaro Plasma Mobile beta2<br />
|-<br />
| UK || Vodafone || Yes || Not tested || Yes || Yes || ModemManager || ALARM & pmOS, modem FW latest - 26 Feb 21<br />
|-<br />
| France || Orange || Yes || Not tested || Yes || Yes || ModemManager || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
| France || SFR || Yes || Not tested || Yes || Yes || ModemManager || Manjaro Phosh Beta6 and later - 9 march 2021<br />
|-<br />
|}<br />
<br />
== North America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| USA || T-Mobile || Yes || No || Yes || Yes || ModemManager || Arch Linux Arm 2020/11/29, Mobian Phosh, Manjaro KDE Plasma Mobile<br />
|-<br />
| USA || T-Mobile(MetroPCS) || Yes || No || Yes || Yes || ModemManager || Mobian 2021/3/20<br />
|-<br />
| USA || T-Mobile || Yes - buggy || No || Yes - buggy || Yes - buggy || Ofono || Manjaro Plasma Dev 2020/11/21 & Ubuntu Touch 2020/11/26 & KDE NEON 2020/11/02<br />
|-<br />
| USA || Red Pocket || Yes || Not tested || Yes || Not tested || ModemManager || mobian-pinephone-phosh-2020/12/15<br />
|-<br />
| USA || Verizon || Yes || Not tested || Yes || Yes || ModemManager || mobian-pinephone-phosh-2021/3/1<br />
|-<br />
| Canada || Freedom || Yes || Not tested || Yes || Yes || ModemManager || Arch Pinephone Phosh AP: internet.windmobile.ca 2021/4/25 <br />
|-<br />
|}<br />
<br />
== South America ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
== Australia / Oceania ==<br />
{| class="wikitable sortable"<br />
!Country || Carrier name || SMS || MMS || Calls || Data || Ofono or ModemManager || Tested OS with version<br />
|-<br />
| Test || Test || Yes || Yes || Yes || Yes || ModemManager || TestOS 20201129<br />
|-<br />
|}<br />
<br />
= Special carrier notes =<br />
Some carriers might support only certain frequencies or might require certain settings in Ofono or ModemManager. The following is a list of collected notes for carriers regarding special settings, hints or information:<br />
<br />
== USA ==<br />
=== AT&T ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page], AT&T's primary bands are 12 and 17 - 700ac and 700 MHz respectively. The PinePhone seems to work out-of-the-box with AT&T. Activating a SIM works. Calls and SMS messages work. VoLTE is as yet untested.<br />
<br />
However, it is likely AT&T will drop support with their network upgrade in the near future like their child company Cricket Wireless already has. [https://www.att.com/ecms/dam/att/consumer/help/pdf/Devices-Working-on-ATT-Network.pdf This page] lists their supported devices for their new network.<br />
<br />
=== Cricket Wireless ===<br />
Cricket wireless is a MVNO that uses AT&T's network. VoLTE was fully supported, but the PinePhone is no longer considered a compatible device in the US by the carrier (as of March 2021).<br />
<br />
=== SimpleMobile ===<br />
SimpleMobile is a T-Mobile prepaid MVNO operating in the United States. 4G LTE, VoLTE, data, and SMS all work on the PinePhone after activation. Activation can be done online without extra software or assistance, go to https://www.simplemobile.com/activation/byopcollectsim and make sure you have your SIM card and IMEI ready.<br />
<br />
=== Sprint ===<br />
Sprint is currently not supported due to unknown reasons. Any input regarding this issue is highly appreciated.<br />
<br />
=== T-Mobile ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
T-Mobile's primary frequency band for the United States is 12 (700ac MHz).<br />
<br />
T-Mobile's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/t-mobile-united-states this page].<br />
<br />
While the PinePhone's modem does support all LTE bands that T-Mobile uses in the US (And is one of the best choices for band support with the PinePhone's modem in the US), VoLTE is still listed as "Under development" by the modem manufacturer. T-Mobile's system also does not list the PinePhone as a compatible device due to this lack of official VoLTE support. The modem is capable of working on T-Mobile with VoLTE support enabled.<br />
<br />
=== Verizon ===<br />
According to [https://ltefix.com/wp-content/uploads/USA-Major-Carriers-Bands-Frequencies-CA.pdf this page],<br />
Verizon's primary frequency band for the United States is 13 (700 MHz). Verizon's bands and protocols are summarized on<br />
[https://www.frequencycheck.com/carriers/verizon-wireless-united-states this page]. According to the same page, Verizon might restrict their network to only approved devices.<br />
<br />
Some users reported that they were able to activate their Verizon SIM by using an Verizon-approved burner phone and then inserting the SIM into the PinePhone.<br />
<br />
=== Red Pocket ===<br />
Red Pocket works with the pinephone. Calls and sms are working. Data not tested yet.<br />
<br />
== Australia ==<br />
=== Telstra ===<br />
According to [https://www.frequencycheck.com/carriers/telstra-australia this page], Telstra uses the LTE B1, B3 and B28 variants, which are all supported by the EG25-G modem.<br />
<br />
= Known issues =<br />
Known issues:<br />
* The [https://www.frequencycheck.com/models FrequencyCheck model page] does not list either Pine64 or the PinePhone.<br />
* T-Mobile's system does not list the PinePhone as a compatible device due to the lack of official VoLTE support from the manufacturer, despite the fact that it does work.<br />
* MMS doesn't currently work in any distribution on the PinePhone by default. This means images and group chats will not work in text messages.<br />
* Some providers may allow only certain known devices identified by their [https://en.wikipedia.org/wiki/Type_Allocation_Code Type Allocation Code].<br />
<br />
= Resources =<br />
* IMEI - [https://en.wikipedia.org/wiki/International_Mobile_Equipment_Identity International Mobile Equipment Identity]<br />
<br />
<br />
[[Category:PinePhone]]</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10134PinePhone MMS with Matrix2021-04-27T22:06:49Z<p>Silver: </p>
<hr />
<div>This is a possible way to get mms fully working by relaying sms to a matrix server with a bridge from mmsd, and using the fractal matrix client to interact with them. Most of this should be cut and pastable. On Mobian, incoming and outgoing mms works with images displayed in line. Outgoing messages over the max size are sent as a link. The link will not resolve if matrix is hosted on the pinephone itself.<br />
<br />
This is being tested on mobian and arch with phosh.<br />
<br />
On arch matrix-synapse 1.29.0-1, fractal 4.4.0-2 (saving login doesn't work), kop316 mmsd v0.3 -- Works for sms, but images don't go through in or out. Unresolvable links are sent out, so maybe small images will go?<br />
<br />
On mobian I'm using matrix-synapse-py3 1.30.0+bionic1 (on a remote VPS server), fractal 4.4.0-2 (and saving the login actually works), kop316 mmsd 0.1-2.2, and images DO go through in and out, with resolvable links out for large images. With matrix_synapse-1.32.2 from pip installed locally images are received but unresolvable links are sent, perhaps this works fine with smaller images though.<br />
<br />
=Install packages=<br />
==arch==<br />
start with a nice and up to date danctnix arch arm pinephone install, mine is from April 20 2021. Ssh into the pinephone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
==mobian==<br />
<br />
=Set up Matrix Synapse on localhost=<br />
<br />
Skip this if you will be using a remote homeserver. Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
Start the service and add a new user. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pinephone<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mmsbridge<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pinephone and password pinephone<br />
<br />
=Install MMSD=<br />
Grab the git repo and install it<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for tmobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install mms bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure mms bridge==<br />
This will mostly take care of editing the config for you if you are running a local matrix server.<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mmsbridge:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mmsbridge"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pinephone:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up mms bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Needs more testing to find problems. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the mms bridge can use. The ones the bridge creates work fine though.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10132PinePhone MMS with Matrix2021-04-27T21:57:58Z<p>Silver: Silver moved page Arch matrix mms to Pinephone MMS with Matrix</p>
<hr />
<div>This is a possible way to get mms fully working by running a localhost matrix server, a bridge between mmsd and matrix, and the fractal matrix client to interact with them. Most of this should be cut and pastable. <br />
<br />
=Install packages=<br />
start with a nice and up to date danctnix arch arm pinephone install, mine is from April 20 2021. Ssh into the pinephone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
=Set up Matrix Synapse=<br />
<br />
Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
Start the service and add a new user. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pinephone<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mmsbridge<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pinephone and password pinephone<br />
<br />
=Install MMSD=<br />
Grab the git repo and install it<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for tmobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install mms bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure mms bridge==<br />
This will mostly take care of editing the config for you<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mmsbridge:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mmsbridge"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pinephone:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up mms bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Needs more testing to find problems. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the mms bridge can use. The ones the bridge creates work fine though.<br />
<br />
I have gotten a test sms through this so far, and a test mms has not arrived yet.<br />
<br />
Incoming and outgoing images did work with matrix on a namecheap vps with fractal on mobian so I think it can be made to work here.<br />
<br />
matrix-synapse 1.29.0-1, fractal 4.4.0-2, kop316 mmsd v0.3 -- Works, but images don't go through.<br />
<br />
On mobian I'm using matrix-synapse-py3 1.30.0+bionic1 (on a remote VPS server), fractal 4.4.0-2 (and saving the login actually works), kop316 mmsd 0.1-2.2, and images DO go through. with matrix_synapse-1.32.2 from pip installed locally images are received but broken links are sent.<br />
<br />
Going to try to downgrade mmsd and see if that helps... It does not. Might be worth trying a newer synapse on arch through pip. Maybe some support libs are missing? I'm working on redoing all of this for mobian.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10052PinePhone MMS with Matrix2021-04-26T00:02:37Z<p>Silver: /* Done */</p>
<hr />
<div>This is a possible way to get mms fully working by running a localhost matrix server, a bridge between mmsd and matrix, and the fractal matrix client to interact with them. Most of this should be cut and pastable. <br />
<br />
=Install packages=<br />
start with a nice and up to date danctnix arch arm pinephone install, mine is from April 20 2021. Ssh into the pinephone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
=Set up Matrix Synapse=<br />
<br />
Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
Start the service and add a new user. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pinephone<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mmsbridge<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pinephone and password pinephone<br />
<br />
=Install MMSD=<br />
Grab the git repo and install it<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for tmobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install mms bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure mms bridge==<br />
This will mostly take care of editing the config for you<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mmsbridge:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mmsbridge"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pinephone:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up mms bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Needs more testing to find problems. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the mms bridge can use. The ones the bridge creates work fine though.<br />
<br />
I have gotten a test sms through this so far, and a test mms has not arrived yet.<br />
<br />
Incoming and outgoing images did work with matrix on a namecheap vps with fractal on mobian so I think it can be made to work here.<br />
<br />
matrix-synapse 1.29.0-1, fractal 4.4.0-2, kop316 mmsd v0.3 -- Works, but images don't go through.<br />
<br />
On mobian I'm using matrix-synapse-py3 1.30.0+bionic1 (on a remote VPS server), fractal 4.4.0-2 (and saving the login actually works), kop316 mmsd 0.1-2.2, and images DO go through. with matrix_synapse-1.32.2 from pip installed locally images are received but broken links are sent.<br />
<br />
Going to try to downgrade mmsd and see if that helps... It does not. Might be worth trying a newer synapse on arch through pip. Maybe some support libs are missing? I'm working on redoing all of this for mobian.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10051PinePhone MMS with Matrix2021-04-25T23:53:10Z<p>Silver: /* Done */</p>
<hr />
<div>This is a possible way to get mms fully working by running a localhost matrix server, a bridge between mmsd and matrix, and the fractal matrix client to interact with them. Most of this should be cut and pastable. <br />
<br />
=Install packages=<br />
start with a nice and up to date danctnix arch arm pinephone install, mine is from April 20 2021. Ssh into the pinephone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
=Set up Matrix Synapse=<br />
<br />
Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
Start the service and add a new user. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pinephone<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mmsbridge<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pinephone and password pinephone<br />
<br />
=Install MMSD=<br />
Grab the git repo and install it<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for tmobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install mms bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure mms bridge==<br />
This will mostly take care of editing the config for you<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mmsbridge:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mmsbridge"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pinephone:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up mms bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Needs more testing to find problems. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the mms bridge can use. The ones the bridge creates work fine though.<br />
<br />
I have gotten a test sms through this so far, and a test mms has not arrived yet.<br />
<br />
Incoming and outgoing images did work with matrix on a namecheap vps with fractal on mobian so I think it can be made to work here.<br />
<br />
matrix-synapse 1.29.0-1, fractal 4.4.0-2, kop316 mmsd v0.3 -- Works, but images don't go through.<br />
<br />
On mobian I'm using matrix-synapse-py3 1.30.0+bionic1 (on a remote VPS server), fractal 4.4.0-2 (and saving the login actually works), kop316 mmsd 0.1-2.2, and images DO go through. <br />
<br />
Going to try to downgrade mmsd and see if that helps... It does not. Might be worth trying a newer synapse on arch through pip. Maybe some support libs are missing? I'm working on redoing all of this for mobian.</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10042PinePhone MMS with Matrix2021-04-25T19:14:57Z<p>Silver: </p>
<hr />
<div>This is a possible way to get mms fully working by running a localhost matrix server, a bridge between mmsd and matrix, and the fractal matrix client to interact with them. Most of this should be cut and pastable. <br />
<br />
=Install packages=<br />
start with a nice and up to date danctnix arch arm pinephone install, mine is from April 20 2021. Ssh into the pinephone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
=Set up Matrix Synapse=<br />
<br />
Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
Start the service and add a new user. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pinephone<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mmsbridge<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pinephone and password pinephone<br />
<br />
=Install MMSD=<br />
Grab the git repo and install it<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for tmobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install mms bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure mms bridge==<br />
This will mostly take care of editing the config for you<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mmsbridge:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mmsbridge"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pinephone:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up mms bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Needs more testing to find problems. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the mms bridge can use. The ones the bridge creates work fine though.<br />
<br />
I have gotten a test sms through this so far, and a test mms has not arrived yet.<br />
<br />
Incoming and outgoing images did work with matrix on a namecheap vps with fractal on mobian so I think it can be made to work here.<br />
<br />
matrix-synapse 1.29.0-1, fractal 4.4.0-2, kop316 mmsd v0.3 -- Works, but images don't go through.<br />
<br />
On mobian I'm using matrix-synapse-py3 1.30.0+bionic1, fractal 4.4.0-2 (and saving the login actually works), kop316 mmsd 0.1-2.2, and images DO go through. <br />
<br />
Going to try to downgrade mmsd and see if that helps...</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_MMS_with_Matrix&diff=10019PinePhone MMS with Matrix2021-04-25T06:27:35Z<p>Silver: Created page with "This is a possible way to get mms fully working by running a localhost matrix server, a bridge between mmsd and matrix, and the fractal matrix client to interact with them. Mo..."</p>
<hr />
<div>This is a possible way to get mms fully working by running a localhost matrix server, a bridge between mmsd and matrix, and the fractal matrix client to interact with them. Most of this should be cut and pastable. <br />
<br />
=Install packages=<br />
start with a nice and up to date danctnix arch arm pinephone install, mine is from April 20 2021. Ssh into the pinephone and then run this to install all the needed packages<br />
<br />
<pre><br />
sudo pacman -Sy matrix-synapse fractal python-matrix_client python-gobject git meson ninja base-devel python-matrix-nio python-dbus<br />
</pre><br />
<br />
=Set up Matrix Synapse=<br />
<br />
Make a new config with the server name set to local host. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo python -m synapse.app.homeserver --server-name localhost --config-path homeserver.yaml --generate-config --report-stats=no<br />
</pre><br />
<br />
Start the service and add a new user. <br />
<br />
<pre><br />
cd /etc/synapse/<br />
sudo systemctl enable synapse<br />
sudo systemctl start synapse<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be pinephone<br />
register_new_matrix_user -c homeserver.yaml http://localhost:8008 # New user name and pw will both be mmsbridge<br />
</pre><br />
<br />
Open fractal and log into the homeserver at http://localhost:8008 with username pinephone and password pinephone<br />
<br />
=Install MMSD=<br />
Grab the git repo and install it<br />
<br />
<pre><br />
cd ~<br />
git clone https://source.puri.sm/kop316/mmsd.git<br />
cd mmsd<br />
meson _build<br />
meson compile -C _build<br />
meson test -C _build<br />
sudo meson install -C _build<br />
</pre><br />
<br />
==Settings for tmobile==<br />
This config works for me<br />
<br />
<pre><br />
mkdir -p ~/.mms/modemmanager/<br />
vi ~/.mms/modemmanager/ModemManagerSettings<br />
<br />
[Modem Manager]<br />
CarrierMMSC=http://mms.msg.eng.t-mobile.com/mms/wapenc<br />
MMS_APN=fast.t-mobile.com<br />
CarrierMMSProxy=NULL<br />
AutoProcessOnConnection=true<br />
</pre><br />
<br />
==Start MMSD ModemManager service==<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmsd-mm.service<br />
<br />
[Unit]<br />
Description=Multimedia Messaging Service Daemon<br />
After=ModemManager.service<br />
<br />
[Service]<br />
ExecStart=/usr/local/bin/mmsd -n -d<br />
<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmsd-mm.service<br />
systemctl enable mmsd-mm.service --user<br />
systemctl start mmsd-mm --user<br />
</pre><br />
<br />
=Install mms bridge=<br />
Grab it from git and put things in places<br />
<br />
<pre><br />
cd ~<br />
git clone https://gitlab.com/untidylamp/mmmpuppet.git<br />
cd mmmpuppet<br />
chmod +x mmmpuppet.py<br />
sudo cp mmm*.py /usr/local/bin/<br />
mkdir -p $HOME/.config/mmm/<br />
cp conf.json.sample $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
==Configure mms bridge==<br />
This will mostly take care of editing the config for you<br />
<br />
<pre><br />
sed -i 's^"https://matrix-client.matrix.org"^"http://localhost:8008"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@bot_account:matrix.org"^"@mmsbridge:localhost"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"Change_me"^"mmsbridge"^' $HOME/.config/mmm/conf.json<br />
sed -i 's^"@your_accounts:matrix.org"^"@pinephone:localhost"^' $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
You actually have to fill these two out yourself. I put "US" and my +1 and rest of 10 digit number.<br />
<br />
<pre><br />
vi $HOME/.config/mmm/conf.json<br />
<br />
"cell_number": "+15554441234",<br />
"cell_country": "CA",<br />
</pre><br />
<br />
<br />
Now we need to run it once to process the config file and remove secrets<br />
<br />
<pre><br />
/usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
check it out now<br />
<br />
<pre><br />
cat $HOME/.config/mmm/conf.json<br />
</pre><br />
<br />
If it doesn't change the file to remove all the linebreaks then it didn't like it. Figure out why by looking at the log file.<br />
<br />
<pre><br />
cat ~/.config/mmm/mmmpuppet.log<br />
</pre><br />
<br />
Go fix whatever went wrong. Which should be nothing. You should have seen a message like this as output before it returns you to a prompt:<br />
<br />
<pre><br />
Login successful. Config updated with token. Run again to start bridge.<br />
</pre><br />
<br />
==Set up mms bridge service==<br />
<br />
Make systemd unit<br />
<br />
<pre><br />
sudo vi /usr/lib/systemd/user/mmmpuppet.service<br />
<br />
[Unit]<br />
Description=Starts mmmpuppet interface<br />
After=mmsd-mm.service<br />
<br />
[Service]<br />
ExecStart=/usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
Restart=on-failure<br />
RestartSec=10s<br />
<br />
[Install]<br />
WantedBy=default.target<br />
</pre><br />
<br />
and start it<br />
<br />
<pre><br />
sudo chmod 644 /usr/lib/systemd/user/mmmpuppet.service<br />
systemctl enable mmmpuppet.service --user<br />
systemctl start mmmpuppet.service --user<br />
</pre><br />
<br />
done? see if services are running:<br />
<br />
<pre><br />
ps aux | grep mm<br />
</pre><br />
<br />
should show something like this even after reboot<br />
<br />
<pre><br />
alarm 6374 0.0 0.3 235364 7752 ? Ssl 22:44 0:00 /usr/local/bin/mmsd -n -d<br />
alarm 6825 9.8 2.7 224976 54188 ? Ssl 22:52 0:05 /usr/bin/python3 /usr/local/bin/mmmpuppet.py<br />
</pre><br />
<br />
=Done=<br />
At this point if you get a message a new room should be created by the bridge bot which you will be invited to. Needs more testing to find problems. Outgoing works for replies but I can't seem to find the 'set topic' button so new rooms can't be created that the mms bridge can use. The ones the bridge creates work fine though.<br />
<br />
I have gotten a test sms through this so far, and a test mms has not arrived yet.<br />
<br />
Incoming and outgoing images did work with matrix on a namecheap vps with fractal on mobian so I think it can be made to work here.</div>Silverhttps://wiki.pine64.org/index.php?title=User:Silver/3d_printed_a_folding_keyboard_mostly&diff=6530User:Silver/3d printed a folding keyboard mostly2020-08-12T00:38:24Z<p>Silver: </p>
<hr />
<div>=Current status=<br />
You cannot type on this yet.<br />
<br />
<br />
Right now I'm working on finishing up the back piece that attaches to the phone, and continuing work on a front piece that a keyboard or gamepad module can fit into.<br />
<br />
I'm guessing wildly but progress looks something like this:<br />
<br />
phone back: 80% done<br />
<br />
hinge: 40% done<br />
<br />
lid: 20% done<br />
<br />
keyboard module: 0%<br />
<br />
interface hardware: 0%<br />
<br />
software support: 0%<br />
<br />
=Stuff=<br />
<br />
The rev10 files include a folding mechanism with a cable passage. Currently looking for feedback for problems on this one before I do rev 11.<br />
<br />
https://www.youmagine.com/designs/pinephone-folding-keyboard-mockup<br />
<br />
https://ibb.co/album/ScDttH<br />
<br />
===no hinge===<br />
rev9aback.stl is a model that should screw nicely to the back of a pinephone but doesn't have any of the hinge parts so you can use it for other pinephone projects.<br />
<br />
=Development updates=<br />
===rev 10 problems===<br />
Looking for confirmation and suggestions on solutions for these issues with rev 10 that I would like to fix in 11<br />
<br />
* Base layer too thin on lid: fixed<br />
<br />
* Base layer too thick on phone side: fixed<br />
<br />
* doesn't have a reset button hole<br />
<br />
* lid is flimsy, could use a thicker wall<br />
<br />
* still need side buttons worked out<br />
<br />
* hinge gaps are all wrong<br />
<br />
* hinge should rest on a hingepin not on the cable passage cup faces<br />
<br />
* maybe include a washer or two in the hinge<br />
<br />
* camera hole is really ugly<br />
<br />
* headphone jack is weak<br />
<br />
* charger hole is ugly<br />
<br />
* need to decide on an actual size if using nuts and bolts<br />
<br />
* bumps for holding angle should be deeper<br />
<br />
* screw holes for pinephone might be too big?<br />
<br />
* lid screwholes are not very useful. Maybe posts?<br />
<br />
* is removing the antenna components in the rear frame safe?</div>Silverhttps://wiki.pine64.org/index.php?title=User:Silver/3d_printed_a_folding_keyboard_mostly&diff=6522User:Silver/3d printed a folding keyboard mostly2020-08-11T02:53:03Z<p>Silver: /* Current status */</p>
<hr />
<div>=Current status=<br />
You cannot type on this yet.<br />
<br />
<br />
Right now I'm working on finishing up the back piece that attaches to the phone, and continuing work on a front piece that a keyboard or gamepad module can fit into.<br />
<br />
I'm guessing wildly but progress looks something like this:<br />
<br />
phone back: 80% done<br />
<br />
hinge: 40% done<br />
<br />
lid: 20% done<br />
<br />
keyboard module: 0%<br />
<br />
interface hardware: 0%<br />
<br />
software support: 0%<br />
<br />
=Stuff=<br />
<br />
The rev10 files include a folding mechanism with a cable passage. Currently looking for feedback for problems on this one before I do rev 11.<br />
<br />
https://www.youmagine.com/designs/pinephone-folding-keyboard-mockup<br />
<br />
https://ibb.co/album/ScDttH<br />
<br />
===no hinge===<br />
rev9aback.stl is a model that should screw nicely to the back of a pinephone but doesn't have any of the hinge parts so you can use it for other pinephone projects.<br />
<br />
=Development updates=<br />
===rev 10 problems===<br />
Looking for confirmation and suggestions on solutions for these issues with rev 10 that I would like to fix in 11<br />
<br />
* Base layer too thin on lid: fixed<br />
<br />
* Base layer too thick on phone side: fixed<br />
<br />
* doesn't have a reset button hole<br />
<br />
* lid is flimsy, could use a thicker wall<br />
<br />
* still need side buttons worked out<br />
<br />
* hinge gaps are all wrong<br />
<br />
* hinge should rest on a hingepin not on the cable passage cup faces<br />
<br />
* maybe include a washer or two in the hinge<br />
<br />
* camera hole is really ugly<br />
<br />
* headphone jack is weak<br />
<br />
* charger hole is ugly<br />
<br />
* need to decide on an actual size if using nuts and bolts<br />
<br />
* bumps for holding angle should be deeper<br />
<br />
* screw holes for pinephone might be too big?<br />
<br />
* lid screwholes are not very useful. Maybe posts?</div>Silverhttps://wiki.pine64.org/index.php?title=User:Silver/3d_printed_a_folding_keyboard_mostly&diff=6521User:Silver/3d printed a folding keyboard mostly2020-08-11T02:37:37Z<p>Silver: /* Stuff */</p>
<hr />
<div>=Current status=<br />
You cannot type on this yet.<br />
<br />
=Stuff=<br />
<br />
The rev10 files include a folding mechanism with a cable passage. Currently looking for feedback for problems on this one before I do rev 11.<br />
<br />
https://www.youmagine.com/designs/pinephone-folding-keyboard-mockup<br />
<br />
https://ibb.co/album/ScDttH<br />
<br />
===no hinge===<br />
rev9aback.stl is a model that should screw nicely to the back of a pinephone but doesn't have any of the hinge parts so you can use it for other pinephone projects.<br />
<br />
=Development updates=<br />
===rev 10 problems===<br />
Looking for confirmation and suggestions on solutions for these issues with rev 10 that I would like to fix in 11<br />
<br />
* Base layer too thin on lid: fixed<br />
<br />
* Base layer too thick on phone side: fixed<br />
<br />
* doesn't have a reset button hole<br />
<br />
* lid is flimsy, could use a thicker wall<br />
<br />
* still need side buttons worked out<br />
<br />
* hinge gaps are all wrong<br />
<br />
* hinge should rest on a hingepin not on the cable passage cup faces<br />
<br />
* maybe include a washer or two in the hinge<br />
<br />
* camera hole is really ugly<br />
<br />
* headphone jack is weak<br />
<br />
* charger hole is ugly<br />
<br />
* need to decide on an actual size if using nuts and bolts<br />
<br />
* bumps for holding angle should be deeper<br />
<br />
* screw holes for pinephone might be too big?<br />
<br />
* lid screwholes are not very useful. Maybe posts?</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_Modding&diff=6520PinePhone Modding2020-08-11T02:35:20Z<p>Silver: </p>
<hr />
<div>There are a number of options to hardware mod the PinePhone.<br />
<br />
Some are upgrades to fix issues that were not done optimally in the production of that version of the electronics, and some are to add options that were not part of the phone spec.<br />
<br />
== PRO TIP ==<br />
Make pictures of the situation before and after your mods, so you can comare the change, and don't need to disassemble the device to get the right pics later.<br />
<br />
==Device Specific Mods ==<br />
There are a nr of upgrades possible for the different versions of the PinePhone.<br />
<br />
=== "Don't be evil" ===<br />
*<br />
<br />
=== BraveHeart ===<br />
*PMIC mod - Stops the battery drain from a shutdown phone, draining the battery to 0V.<br />
*VCONN mod - Unblocks the USB-C power negotiation rail, so convergence functions are unlocked.<br />
<br />
=== UBPorts Community edition ===<br />
*VCONN mod - Unblocks the USB-C power negotiation rail, so convergence functions are unlocked.<br />
<br />
There are also a number of mods that can be done adding more functions by adding extra hardware to the pogo pins, and a number of options to change the screen protector.<br />
<br />
At this moment there are not many pogo addons, and most are just connector boards. Likely the makers will add links to these projects to this page. Pine is looking into adding a N900 style keyboard attached to these pins.<br />
<br />
== PMIC mod ==<br />
The original description of this fix is given on megi's pager here https://xnux.eu/devices/pp-pmic-fix.jpg<br />
== VCONN mod ==<br />
The original description of this fix is given on megi's pager here https://xnux.eu/devices/pp-usbc-fix.jpg<br />
There is a discussion on the merits of the different ways to do the fix<br />
<br />
=== VCONN mod, Removal only ===<br />
[[PinePhone_1.2_VCONN_Hardware_Fix]]<br />
<br />
There are now a few documented ways,<br />
*Removal only, the tweezer "stupid" way: https://www.youtube.com/watch?v=j3jc7Mvn9Eo<br />
*Removal only, the soldering iron "less stupid" way: https://www.youtube.com/watch?v=ZqOb45N2sMc<br />
There are hopefully videos coming doing it the proper way, and so they can be linked here.<br />
<br />
After this the firmware for the power negotiation chip needs to be upgraded, this can be done by running the factory test image, version http://images.postmarketos.org/pinephone/pine64-pinephone-20200724-factorytest55.img.xz or higher. This will do the firmware flashing and respond with a message indicating the state. After this the phone is ready for its added functions.<br />
ANX states:<br />
*No CC Fix - Fix not applied<br />
*No USB Cable - No USBC connection, cannot upgrade firmware<br />
*OK - Firmware Applied, you are all set<br />
<br />
=== VCONN mod, Replacement ===<br />
Using 2x NCP334FCT2G you could do the full fix, making VCONN powered devices able to negotiate power. IT needs the parts to be removed first without damaging the pads, and then replacing the parts.<br />
<br />
==Laser cut parts==<br />
Mcyam2 has created some laser cut templates for the rear facing components here:<br />
<br />
https://imgur.com/a/LAUatOa<br />
<br />
https://anonfiles.com/L0BeK5L5oe/ppsvg-backplate-CUTOUT_svg<br />
<br />
Originally based on silver's work on a 3d printed rear frame<br />
<br />
==3D Printed parts==<br />
<br />
[[Silver 3d printed a folding keyboard mostly]]<br />
<br />
<br />
Silver has created a 3d printable rear frame for pinephone, and used it to create a folding keyboard design (work in progress).<br />
<br />
https://ibb.co/album/ScDttH<br />
<br />
https://www.youmagine.com/designs/pinephone-folding-keyboard-mockup</div>Silverhttps://wiki.pine64.org/index.php?title=User:Silver/3d_printed_a_folding_keyboard_mostly&diff=6519User:Silver/3d printed a folding keyboard mostly2020-08-11T02:25:59Z<p>Silver: </p>
<hr />
<div>=Current status=<br />
You cannot type on this yet.<br />
<br />
=Stuff=<br />
rev9aback.stl is a model that should screw nicely to the back of a pinephone and replaces it's stock frame.<br />
<br />
the rev10 files include a folding mechanism with a cable passage. Currently looking for feedback for problems on this one before I do rev 11.<br />
<br />
https://www.youmagine.com/designs/pinephone-folding-keyboard-mockup<br />
<br />
https://ibb.co/album/ScDttH<br />
<br />
=Development updates=<br />
===rev 10 problems===<br />
Looking for confirmation and suggestions on solutions for these issues with rev 10 that I would like to fix in 11<br />
<br />
* Base layer too thin on lid: fixed<br />
<br />
* Base layer too thick on phone side: fixed<br />
<br />
* doesn't have a reset button hole<br />
<br />
* lid is flimsy, could use a thicker wall<br />
<br />
* still need side buttons worked out<br />
<br />
* hinge gaps are all wrong<br />
<br />
* hinge should rest on a hingepin not on the cable passage cup faces<br />
<br />
* maybe include a washer or two in the hinge<br />
<br />
* camera hole is really ugly<br />
<br />
* headphone jack is weak<br />
<br />
* charger hole is ugly<br />
<br />
* need to decide on an actual size if using nuts and bolts<br />
<br />
* bumps for holding angle should be deeper<br />
<br />
* screw holes for pinephone might be too big?<br />
<br />
* lid screwholes are not very useful. Maybe posts?</div>Silverhttps://wiki.pine64.org/index.php?title=User:Silver/3d_printed_a_folding_keyboard_mostly&diff=6518User:Silver/3d printed a folding keyboard mostly2020-08-11T02:23:50Z<p>Silver: Created page with "=Current status= You cannot type on this yet. =Stuff= rev9aback.stl is a model that should screw nicely to the back of a pinephone and replaces it's stock frame. the rev10 f..."</p>
<hr />
<div>=Current status=<br />
You cannot type on this yet.<br />
<br />
=Stuff=<br />
rev9aback.stl is a model that should screw nicely to the back of a pinephone and replaces it's stock frame.<br />
<br />
the rev10 files include a folding mechanism with a cable passage. Currently looking for feedback for problems on this one before I do rev 11.<br />
<br />
=Development updates=<br />
<br />
===rev 10 problems===<br />
Base layer too thin on lid: fixed<br />
<br />
Base layer too thick on phone side: fixed<br />
<br />
doesn't have a reset button hole<br />
<br />
lid is flimsy, could use a thicker wall<br />
<br />
still need side buttons worked out<br />
<br />
hinge gaps are all wrong<br />
<br />
hinge should rest on a hingepin not on the cable passage cup faces<br />
<br />
maybe include a washer or two in the hinge<br />
<br />
camera hole is really ugly<br />
<br />
headphone jack is weak<br />
<br />
charger hole is ugly<br />
<br />
need to decide on an actual size if using nuts and bolts<br />
<br />
bumps for holding angle should be deeper<br />
<br />
screw holes for pinephone might be too big?<br />
<br />
lid screwholes are not very useful. Maybe posts?</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_Modding&diff=6517PinePhone Modding2020-08-10T22:07:20Z<p>Silver: /* 3D Printed parts */</p>
<hr />
<div>There are a number of options to hardware mod the PinePhone.<br />
<br />
Some are upgrades to fix issues that were not done optimally in the production of that version of the electronics, and some are to add options that were not part of the phone spec.<br />
<br />
== PRO TIP ==<br />
Make pictures of the situation before and after your mods, so you can comare the change, and don't need to disassemble the device to get the right pics later.<br />
<br />
==Device Specific Mods ==<br />
There are a nr of upgrades possible for the different versions of the PinePhone.<br />
<br />
=== "Don't be evil" ===<br />
*<br />
<br />
=== BraveHeart ===<br />
*PMIC mod - Stops the battery drain from a shutdown phone, draining the battery to 0V.<br />
*VCONN mod - Unblocks the USB-C power negotiation rail, so convergence functions are unlocked.<br />
<br />
=== UBPorts Community edition ===<br />
*VCONN mod - Unblocks the USB-C power negotiation rail, so convergence functions are unlocked.<br />
<br />
There are also a number of mods that can be done adding more functions by adding extra hardware to the pogo pins, and a number of options to change the screen protector.<br />
<br />
At this moment there are not many pogo addons, and most are just connector boards. Likely the makers will add links to these projects to this page. Pine is looking into adding a N900 style keyboard attached to these pins.<br />
<br />
== PMIC mod ==<br />
The original description of this fix is given on megi's pager here https://xnux.eu/devices/pp-pmic-fix.jpg<br />
== VCONN mod ==<br />
The original description of this fix is given on megi's pager here https://xnux.eu/devices/pp-usbc-fix.jpg<br />
There is a discussion on the merits of the different ways to do the fix<br />
<br />
=== VCONN mod, Removal only ===<br />
[[PinePhone_1.2_VCONN_Hardware_Fix]]<br />
<br />
There are now a few documented ways,<br />
*Removal only, the tweezer "stupid" way: https://www.youtube.com/watch?v=j3jc7Mvn9Eo<br />
*Removal only, the soldering iron "less stupid" way: https://www.youtube.com/watch?v=ZqOb45N2sMc<br />
There are hopefully videos coming doing it the proper way, and so they can be linked here.<br />
<br />
After this the firmware for the power negotiation chip needs to be upgraded, this can be done by running the factory test image, version http://images.postmarketos.org/pinephone/pine64-pinephone-20200724-factorytest55.img.xz or higher. This will do the firmware flashing and respond with a message indicating the state. After this the phone is ready for its added functions.<br />
ANX states:<br />
*No CC Fix - Fix not applied<br />
*No USB Cable - No USBC connection, cannot upgrade firmware<br />
*OK - Firmware Applied, you are all set<br />
<br />
=== VCONN mod, Replacement ===<br />
Using 2x NCP334FCT2G you could do the full fix, making VCONN powered devices able to negotiate power. IT needs the parts to be removed first without damaging the pads, and then replacing the parts.<br />
<br />
==Laser cut parts==<br />
Mcyam2 has created some laser cut templates for the rear facing components here:<br />
<br />
https://imgur.com/a/LAUatOa<br />
<br />
https://anonfiles.com/L0BeK5L5oe/ppsvg-backplate-CUTOUT_svg<br />
<br />
Originally based on silver's work on a 3d printed rear frame<br />
<br />
==3D Printed parts==<br />
Silver has created a 3d printable rear frame for pinephone, and used it to create a folding keyboard design (work in progress).<br />
<br />
https://ibb.co/album/ScDttH<br />
<br />
https://www.youmagine.com/designs/pinephone-folding-keyboard-mockup</div>Silverhttps://wiki.pine64.org/index.php?title=PinePhone_Modding&diff=6515PinePhone Modding2020-08-10T20:05:34Z<p>Silver: </p>
<hr />
<div>There are a number of options to hardware mod the PinePhone.<br />
<br />
Some are upgrades to fix issues that were not done optimally in the production of that version of the electronics, and some are to add options that were not part of the phone spec.<br />
<br />
== PRO TIP ==<br />
Make pictures of the situation before and after your mods, so you can comare the change, and don't need to disassemble the device to get the right pics later.<br />
<br />
==Device Specific Mods ==<br />
There are a nr of upgrades possible for the different versions of the PinePhone.<br />
<br />
=== "Don't be evil" ===<br />
*<br />
<br />
=== BraveHeart ===<br />
*PMIC mod - Stops the battery drain from a shutdown phone, draining the battery to 0V.<br />
*VCONN mod - Unblocks the USB-C power negotiation rail, so convergence functions are unlocked.<br />
<br />
=== UBPorts Community edition ===<br />
*VCONN mod - Unblocks the USB-C power negotiation rail, so convergence functions are unlocked.<br />
<br />
There are also a number of mods that can be done adding more functions by adding extra hardware to the pogo pins, and a number of options to change the screen protector.<br />
<br />
At this moment there are not many pogo addons, and most are just connector boards. Likely the makers will add links to these projects to this page. Pine is looking into adding a N900 style keyboard attached to these pins.<br />
<br />
== PMIC mod ==<br />
The original description of this fix is given on megi's pager here https://xnux.eu/devices/pp-pmic-fix.jpg<br />
== VCONN mod ==<br />
The original description of this fix is given on megi's pager here https://xnux.eu/devices/pp-usbc-fix.jpg<br />
There is a discussion on the merits of the different ways to do the fix<br />
<br />
=== VCONN mod, Removal only ===<br />
[[PinePhone_1.2_VCONN_Hardware_Fix]]<br />
<br />
There are now a few documented ways,<br />
*Removal only, the tweezer "stupid" way: https://www.youtube.com/watch?v=j3jc7Mvn9Eo<br />
*Removal only, the soldering iron "less stupid" way: https://www.youtube.com/watch?v=ZqOb45N2sMc<br />
There are hopefully videos coming doing it the proper way, and so they can be linked here.<br />
<br />
After this the firmware for the power negotiation chip needs to be upgraded, this can be done by running the factory test image, version http://images.postmarketos.org/pinephone/pine64-pinephone-20200724-factorytest55.img.xz or higher. This will do the firmware flashing and respond with a message indicating the state. After this the phone is ready for its added functions.<br />
ANX states:<br />
*No CC Fix - Fix not applied<br />
*No USB Cable - No USBC connection, cannot upgrade firmware<br />
*OK - Firmware Applied, you are all set<br />
<br />
=== VCONN mod, Replacement ===<br />
Using 2x NCP334FCT2G you could do the full fix, making VCONN powered devices able to negotiate power. IT needs the parts to be removed first without damaging the pads, and then replacing the parts.<br />
<br />
==Laser cut parts==<br />
Mcyam2 has created some laser cut templates for the rear facing components here:<br />
<br />
https://imgur.com/a/LAUatOa<br />
<br />
https://anonfiles.com/L0BeK5L5oe/ppsvg-backplate-CUTOUT_svg<br />
<br />
Originally based on silver's work on a 3d printed rear frame<br />
<br />
==3D Printed parts==<br />
Silver has created a 3d printable rear frame for pinephone, and used it to create a folding keyboard design (work in progress).<br />
<br />
https://www.youmagine.com/designs/pinephone-folding-keyboard-mockup</div>Silver