Giter VIP home page Giter VIP logo

hackthedev / remotepifm Goto Github PK

View Code? Open in Web Editor NEW
7.0 3.0 1.0 9.4 MB

This App allows you to Broadcast your own Music to every radio in a specific range using a custom frequency. It requires a Raspberry Pi and PiFmRds Project found on Github.

License: GNU General Public License v3.0

Java 100.00%
raspberry-pi pifmrds smartphone screenshots hardware-setup hacking-tool android apk app hijacking

remotepifm's Introduction

Doing Dev Stuff ¯\_(ツ)_/¯


Im currently creating a chat platform! Basically, its a self hosted Discord!
Stay tuned!

remotepifm's People

Contributors

hackthedev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

esp64

remotepifm's Issues

Method "cmd()" in ControlActivity.java not returning command output

The following Code is not returning any command output. If anyone can help me here I'd be really happy.

    public String cmd(
            String command) throws Exception {

        try{
            String username = MainActivity._user;
            String password = MainActivity._pass;;
            String hostname = MainActivity._host;
            String port = MainActivity._port;

            JSch jsch = new JSch();
            Session session = jsch.getSession(username, hostname, Integer.parseInt(port));
            session.setPassword(password);

            // Avoid asking for key confirmation
            Properties prop = new Properties();
            prop.put("StrictHostKeyChecking", "no");
            session.setConfig(prop);

            session.connect();

            // SSH Channel
            ChannelExec channelssh = (ChannelExec) session.openChannel("exec");
            ByteArrayOutputStream baos = new ByteArrayOutputStream();
            channelssh.setOutputStream(baos);

            channelssh.setCommand(command);

            channelssh.connect();

            while(true){
                if(channelssh.isClosed()){
                    break;
                }
            }

            channelssh.disconnect();

            return baos.toString();
        } catch (Exception e){
            Log.e("ControlActivity-Login:", e.getMessage());

            return "ERROR";
        }

    }

Although the same function in MainActivity.java does.

    public static String executeRemoteCommand(
            String username,
            String password,
            String hostname,
            int port,
            String command) throws Exception {

        try{
            hostname = hostname.replace(" ", "");

            JSch jsch = new JSch();
            Session session = jsch.getSession(username, hostname, 22);
            session.setPassword(password);

            // Avoid asking for key confirmation
            Properties prop = new Properties();
            prop.put("StrictHostKeyChecking", "no");
            session.setConfig(prop);

            session.connect();

            // SSH Channel
            ChannelExec channelssh = (ChannelExec) session.openChannel("exec");
            ByteArrayOutputStream baos = new ByteArrayOutputStream();
            channelssh.setOutputStream(baos);

            channelssh.setCommand(command);

            channelssh.connect();

            while(true){
                if(channelssh.isClosed()){
                    break;
                }
            }

            channelssh.disconnect();

            return baos.toString();
        } catch (Exception e){
            Log.e("MainActivity-Login:", e.getMessage());

            return "ERROR";
        }

    }

Development paused

Hello everyone.

I wanted to mention that this project has not been updated in a while because my raspberry pi stopped working for no reason. To be honest, it went through a lot of "abuse" and i wouldnt be surprised that it wont work anymore.

My pi breaking wouldnt be an issue normally, but the problem is i cant really order a new one as they are sold out everywhere! We have a local store that sells them for 200€ !!!! Thats insane!

Until the prices are normal again and they have pis again, im going to pause the development for now.


Also

Im planning on readding the screenshots in the readme file

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.