Skip to content

Instantly share code, notes, and snippets.

View nikiizvorski's full-sized avatar
💭
I may be slow to respond.

Niki Izvorski nikiizvorski

💭
I may be slow to respond.
View GitHub Profile
package nikiizvorski.uk.co.ble.ui
import android.view.View
import androidx.lifecycle.*
import dagger.hilt.android.lifecycle.HiltViewModel
import kotlinx.coroutines.*
import kotlinx.coroutines.flow.collect
import nikiizvorski.uk.co.ble.pojos.Photo
import nikiizvorski.uk.co.ble.pojos.Photos
import nikiizvorski.uk.co.ble.repos.NetworkRepository
@nikiizvorski
nikiizvorski / index.js
Created July 25, 2019 06:48
JS App using Cheerio and Request to Firebase Firestore Parser/Scraper
var admin = require("firebase-admin");
var serviceAccount = require("./recipebook-admin.json");
admin.initializeApp({
credential: admin.credential.cert(serviceAccount),
databaseURL: "dburl"
});
const db = admin.firestore();
@nikiizvorski
nikiizvorski / nav_graph
Created May 9, 2019 11:17
Android Jetpack Navigation Refactoring from BottomNavigationView with BackStack and Actions
/** Just to put out there the project was using KTX and Synthetics for the View Integration
First create a menu called nav.xml in the menu folder and fill it like this. **/
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:id="@+id/navigation_home"
android:icon="@drawable/ic_seat"
@nikiizvorski
nikiizvorski / receiver.kt
Last active April 8, 2019 13:52
ViableGrid 6LOWPAN Implementation as a Full Receiver over UDP or TCP you can find here
private val KITCHEN = "224.0.0.251"
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
/*
To start using our sdk please run the sender first and get the channel, panid and the network you want it to be on.
after you find all the things you need by running the sample for the sender with the following command to verify
adb shell lowpanctl status and you verify all the above. Add it to the receiver and restart the sender.
@nikiizvorski
nikiizvorski / transmitter.kt
Last active April 8, 2019 13:58
ViableGrid 6LOWPAN Implementation as a Full Transmitter over UDP or TCP you can find here
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
/*
To start using our sdk please run the sender first and get the channel, panid and the network you want it to be on.
after you find all the things you need by running the sample for the sender with the following command to verify
adb shell lowpanctl status and you verify all the above. Add it to the receiver and restart the sender.
You are all set.