Recover from broken /usr/share/pocket-home/config.json?


#1

I made a mistake editing this file (trying to add surf) and now my Pocket Chip
hangs during boot at the Pocket Chip screen.

Any suggestions on how to repair this?


#2

Oh man, thats a bummer. Are you using the Marshmallow Mod?


If so you could try to re-install it. Or re-flash, then reinstall.
Or, you could try editing your config.json file and seeing if it matches or differs from this:

{
“defaultPage”: “Apps”,
“pages”: [
{
“name”: “Apps”,
“items”: [
{
“name”: “Terminal”,
“icon”: “appIcons/terminal.png”,
“shell”: “vala-terminal -fs 8 -g 20 20”
},
{
“name”: “Write”,
“icon”: “appIcons/texteditor.png”,
“shell”: “leafpad”
},
{
“name”: “Browse Files”,
“icon”: “appIcons/filebrowser.png”,
“shell”: “pcmanfm”
},
{
“name”: “Web Browser”,
“icon”: “/home/chip/Icons/Categories-applications-internet-icon.png”,
“shell”: “dwb”
},
{
“name”: “Notepad”,
“icon”: “/home/chip/Icons/Notepad-icon.png”,
“shell”: “xournal”
},
{
“name”: “Calculator”,
“icon”: “/home/chip/Icons/Calculator-icon.png”,
“shell”: “xcalc”
},
{
“name”: “Get Help”,
“icon”: “appIcons/help.png”,
“shell”: “surf /usr/share/pocketchip-localdoc/index.html”
},
{
“name”: “Play PICO-8”,
“icon”: “appIcons/pico8.png”,
“shell”: “pico8”
},
{
“name”: “Make Music”,
“icon”: “appIcons/musicsequencer.png”,
“shell”: “sunvox”
},
],
“cornerButtons”: [
{
“location”: “TopLeft”,
“name”: “Battery”,
“icon”: “battery_0.png”
},
{
“location”: “TopRight”,
“name”: “WiFi”,
“icon”: “wifiOff.png”
},

This is taken from a back up of my own file. I currently use the Marshmallow Mod, so it may not work with the default interface, but it never hurts to take a look. I’d suggest you copy your file to a tumbdrive and transfer it to a pc so you can open it in a text editor, and see what’s what. I hope this helps!


#3

If you are not using my modified Pocket-home, the only way to recover (without flashing) is to use SSH, if you installed it.
I don’t know if it’s possible to access the Chip flash memory throught usb on a computer. If yes, you can correct the json file as @Kernel_Panic showed

Note: On the modified Pocket-home, when the config.json file cannot be parsed correctly, a popup is shown on startup, proposing you to launch a terminal to let you correct the file