« first day (2841 days earlier)      last day (2122 days later) » 

I have a feeling Dave's kid is going to show up on youtube once the speech skill is acquired
 
lol
Not for a long time hopefully
 
Hah
Imagine if around the age of 11-13 or so the kid googles you and finds this chat
And public transcripts
and thus, today was the last time we saw Dave in r15
 
Thankfully I'm not that easily searched
It takes a certain level of non public information to definitively identify me
 
I dunno, pretty sure your kids would know enough to search, and that employer etc. is in the transcript
Wouldn't be a stretch
Maybe when they're older, 15 or so
Still got some time
 
12:44 AM
If my kid is smart enough to dig through chat transcripts on a programming site, they'll be fine understanding my statements in context
o/ all
 
I'm gonna stop stalking you now
Why redo work that's already done?
pans out zoom on drone
dave <employer.com> shows your email in the transcript
^Repost of removed message without actual employer
Then again, who even knows if this chat exists in a decade
Should back it up somewhere, lots of good stuff here
 
1:17 AM
can I detect a click on a DISABLED button with an "onClickListener" ?
 
1:32 AM
@payne As far as I know, "disabled" means "don't call the onClickListener"
so no
 
1:42 AM
k ty
 
You could just check for a MotionEvent and correlate XY
Or use an OnTouchListener, but I'm forgetting if those actually exist
 
@TristanWiley hahahaha get rekt noob
 
2:20 AM
I'm streaming on twitch if anyone is interested @codeguru42
 
2:51 AM
Say I have this usual Activity Flow:
A1 -> A2 -> A3

An user coming from A3 would always think that pressing the BACK button would bring him back to A2. However, what if I have a button in A1 that sends the user in A3: **how can I make it so that from A3, in that particular case, pressing 'BACK' would bring the user back to A2** ?
 
Overrride onBackPressed, make sure user goes to A2?
 
@payne This seems like odd behavior. As a user, I expect the back button to go back to the previous screen that I navigated from.
 
oh, thank you!
yeah, I just thought this through
I'm going to take another approach
 
The only true approach is to show a popup listing every activity on their device when they press back, and ask them to select one
 
any Room users out there? I'm confused about inserting data. When I try to call my Dao object's insert() function, I get an exception along the lines of "you can't do that on the main UI thread". This is understandable, and I'm looking into using LiveData, but I don't see how LiveData can help with the insert operation.
 
3:03 AM
user image
2
 
 
2 hours later…
5:02 AM
morn
 
5:23 AM
@TristanWiley I stated before I match by name because Mehdi has a new account and I don't want to lose all his data
 
5:55 AM
@Code-Apprentice google has a sample and they do insertions using executors github.com/googlesamples/android-architecture-components/blob/… and i have seem some example where people use asynctask for insertion.
 
On kotlin you can do coroutine probably
 
yes. I have forgotten about coroutine. I started learning it and then never used it in production. I feel its much more simpler than threads
you use coroutines in production tim?
 
6:09 AM
Morning
TGIF
 
Gooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo‌​oooooooooood Morning Everyone!!!!!!! :D
 
Womper, Day by day your work energy is getting increased.
 
has the good reached the second line at any time?
 
Yes
 
there's a chart somewhere
 
6:17 AM
Not cat.
This guac is... sweet?
 
6:39 AM
@Raghunandan I don't use them at all
 
6:50 AM
@ColdFire glad to help, glad to win some bucks.
morning everyone!
@DaveS we never chat anymore. there's a whole world apart. </3. an ocean of tears.
 
hide your irresponsibly low productivity figures, it's the germans!!!!
 
I'm very productive, as usual
 
compiling
 
6:54 AM
nobody can be as unproductive as I already feel without even having started
 
I went to class today, did homework, did actual work, went shopping, and made sketchy guacamole
Not terrible
 
user3894856 requested access. Rep: 102 - Questions: 8 - Answers: 4 (ratio 4:2.0)
 
@TimCastelijns Where's the name check
 
@user3894856 rejected because you have a default username
 
Feeling productive yet?
 
6:56 AM
fuck yeah
 
I removed the name check because it's useless
 
riki requested access. Rep: 144 - Questions: 31 - Answers: 0 (ratio 4:0.0)
 
@riki You need a 4:3 q:a ratio to get access here
 
riki requested access. Rep: 118 - Questions: 21 - Answers: 0 (ratio 4:0.0)
 
lol
Did he just deleted 10 questions?
Someone seems to be desperate
 
6:59 AM
Nope
Two different accounts
 
which is even more desperate... and pathetic!
 
I like the desperation story better
 
@riki Both of you need a 4:3 q:a ratio or better to get access here
I think it will actually ping both of them
 
@TimCastelijns Here is your reminder
 
Impressive
 
7:02 AM
how would you feel if the bot spewed out these messages along with the stats? Not as a accepted/rejected verdict but just a heads up for the requestee, also saving us some typing
 
Go for it
I am a lazy bastard anyway
 
I want the bot to deny people automatically
Like Android Bot used to, may he rest in piece
 
lol show code
 
sigh
 
7:06 AM
😱CF is that you
CF add android tag to this Q pls stackoverflow.com/questions/51552430/…
 
@DaveS tim also uses the username
@TimCastelijns done
 
thx hammered
 
user3894856 requested access. Rep: 102 - Questions: 8 - Answers: 4 (ratio 4:2.0)
 
@user3894856 You changed your name, which is good, but you still need a 4:3 q:a ratio or better to get access here
 
like you typed what I just wrote
 
7:12 AM
Why would I type? I just send signals down the usb lane
 
anyway I saw he has some good answers/questions and seems to be burned by BLE, so why not be a bit open and let him hin?
 
lol
------------^
 
Hmmmm
Alright
 
yeah raghav don't be an elitist bully
 
morning everyone
 
7:13 AM
@user3894856 Welcome! Please read, confirm reading, and follow the room rules before you do anything else: room-15.github.io
 
bows hi
 
warren seems to be in good mood today
 
I made too much guac
Not that I had a choice
Only used one avocado
 
@user3894856 welcome to the room. Please make sure to read the room rules: room-15.github.io
 
@Raghunandan btw in the newest version of kotlin coroutines are graduated to stable. It's a preview of 1.3, not the official release
 
7:14 AM
Well, of course you're gonna be unproductive if you repeat work, Warren!
 
shut up
 
lol
 
@ColdFire Fixed :)
 
slow and duplicate work
 
xD
 
7:15 AM
as if warren became spanish or something.
 
your delay to mimic slow humans is broken. Fix yourself!
Raghav only has those text snippets prepared
 
@WarrenFaith Thank you
 
warrens reaction^
 
you know.. one of these days that might become a meme and actualy end up in the news
 
7:17 AM
I actually write it out each time
 
if it finances my life, I am good with it
 
I have it copied in some sublime window somewhere
But I have so many of those it's faster to just type it out
 
Nobody trusts a bot...
 
you type it out same everytime ?
 
and yet he's almost as fast as a machine
 
7:19 AM
Hi @WarrenFaith, I have read the terms of this room's usage.
 
but have you understood them?
 
@WarrenFaith, yes well understood
 
I doubt that and REALLY urge you to go read them again
 
@CptEric i haven't got it yet but i feel i can get it so will notify you if i got it :)
 
7:21 AM
sure
i'll know later today or monday if i get the flat finally
and i'm dying of nerves
 
medic!
 
^
its friday already
 
it is indeed
 
7:26 AM
@WarrenFaith better than mac
"i think it stopped working. i'll stop working too".
 
Saw in store right now. Title "Air", "Drink as breathe" (vodka)
 
xD
 
I need help with DFP ads. I have searched everywhere but no luck. Does anyone has worked with DFP ads?
 
Did you just insult me? — kerbholz 2 mins ago
well you are doing people php cant help it xD^
I have worked with admob but not with DFP ads
 
Okay, @ColdFire. I have a strange issue. My ad was working fine before few days. But suddenly it stops showing ads. But If I change the package name ads shows perfectly. Do you have any idea about it? I am stuck in this issue from a week.
 
7:31 AM
well then your package name is banned by admob/adsense
what did you do?
 
H.Alioum requested access. Rep: 1 - Questions: 1 - Answers: 0 (ratio 4:0.0)
 
I let the quick typer do that...
 
@H.Alioum you need at least 80 rep to chat here
 
Dima, not your fucking job, seriously
 
7:34 AM
Why not?
 
I told you before
 
Because you are no room owner!
 
we have training for this
 
Nimisha V requested access. Rep: 116 - Questions: 1 - Answers: 31 (ratio 4:124.0)
 
@ColdFire, I have created two sample apps with two different package name one with the same package name where ad failed and one with different package name but it only works with the different package name. What should I do now ?
 
7:35 AM
Just imagine you see someone who could get access? What are you doing? Welcoming him here and then wait for a room owner to act?
Let us deal with it. Period
 
Calm down
 
Don't get me started!
 
you might wanna read the rules again tho @user3894856
 
you're looking at a cached name CF
 
@user3894856 I really have a hard time keeping you in. You did NOT read the rules, you did not pass the very first test and you randomly ping someone for help. LAST Chance: Read the rules within the next 5 minutes or I revoke your access again
 
7:37 AM
yeah tim i know , i was not talking about the name rule tho
 
I have read it already. twice or thrice. I just need help regarding the issue. I am stuck from a week in that issue.
 
no you haven't :/
anyway your issue is simple dont worry about it , your test package name was a banned one so its not showing ads
also remember to use a unique package name next time
 
@raghav how is your byte maths
 
raghav.retreiveByteMathStatus();
 
7:52 AM
@Akruti I have revoked your access as you might have read the rules but you really failed to understand them in multiple ways. I warned you...
 
8:06 AM
can a byte hold both signed and unsigned values together?
 
i think in java, not
but don't trust me 100%
 
I have 32 bits where the 11MSB represent signed value and 23LSB represent unsigned value. I can get the 23 by shifting "i << 11 >> 11" which gives the correct value but if I shift "i >>> 23" I get strange result
 
show value in hex
 
hex(i) = -0x76ffffc4
 
why don't you work in bits directly?
 
8:10 AM
How is your signed value signed?
Is it in 2's complement?
Because if it is, just shifting it won't work
You will need to shift 10 bits
 
And preserve the first bit to preserve the sign
 
i used that lib
 
110 -> 101, not 011
 
yes it is 2's raghav I believe it must be in java
 
8:14 AM
11MSB + 23LSB == 34 bits? 0_o
 
well 21, typo
@RaghavSood do you mean 20? Which 10 or 20? How do you preserve the signed bit when shifting
 
You can't do it in one operation
You will have to shift, zero out the original-but-now-shifted first bit, and set the first bit to the original first bit again
 
so get MSB, >>> 20 and then or with MSB?
 
You could do:
Original number << 1 (drop the sign)
Prev >>> 22 (put the 10 bits in the 10 LSB)
Set the first bit back to the bit you dropped
You could do that part with two OR operations
Well, XOR
 
I suppose it will be prev >>> 32
 
8:19 AM
OR will mess up the rest
 
no
not 32 lol
 
You can check if the sign changed with ((x ^ y) < 0);
If x is your original number, and y is the prev >>> 22 one
If it didn't change, you don't need to change the first bit
If it did, you do
Then to change it just XOR with 10000000000000000000000000000000
Examples are mostly in C/C++, but math doesn't change much between languages
Disclaimer: Probably won't work in JS, because math actually does change there
 
o/
 
it's not work!!
 
Hmmmm
Let me try, give me a few minutes
 
8:35 AM
probably due my lack of knowhow. Let me give some additional info
I have a binarybuffer from which I read 4 bytes with getInt(). These contain the 32 bits mentioned above. 23LSB contain a positive timestamp which I can read no problem, the 11MSB contain a potentially negative temperature. Printing getInt() gives -1996488644
after << 11 >> 11 it gives -1996488704 which I guess is correct because the timestamp that I wrote to it is 60
 
hmm
 
so -1996488704 >>> 23 == 274
but again, 23 + 11??
 
32 mins ago, by Tim Castelijns
well 21, typo
the value in the 11 MSB should be -3000 btw
 
I really don't understand, why just >>> 21 doesn't work
aaaaaha, I get it now
 
enlighten me
 
8:49 AM
wait lemme try
 
> 01110110111111111111111111000100
00000000000111111111111111000100
00000000000000000000001110110111
I'm not sure if I have the correct initial binary though
Can you print your binary out and share?
 
10001001000000000000000000111100
 
Ah yep
Reverse of mine
That's what I though
 
maybe the problem is in the encoding, I write the int with "(-3000 << 21) | 60"
although the encodeNegativeTemp test succeeds
 
> 10001001000000000000000000111100 # Number
00000000000000000000000000111100 # LSB
00000000000000000000000001001000 # MSB minus sign bit
00000000000000000000000000000001 # sign bit
10000000000000000000000001001000 # Sign bit fixed
 
8:57 AM
@TimCastelijns doesn't (-3000 << 21) drops sign bit?
 
Yeah, I suspect the sign bit is added if you have the literal -0x76ffffc4 in your code
Otherwise your encoding will drop it
(unless coincidentally you end up with the same bit after bitshifting)
Even your encoding will need to replicate the sign re-adding part
 
-0x76ffffc4 is just the hex of the binary I gave you 5 mins ago
 
Hex and binary representations don't need signs
If you are applying a sign, you will alter the number
 
just copying the console output
>>> hex(-1996488644)
'-0x76ffffc4'
 
Print out the exact bytes you receive from the device
 
9:03 AM
11 mins ago, by Tim Castelijns
10001001000000000000000000111100
I was just printing this as hex in python console to see
 
python is very snakey.
 
Yeah, this won't actually restore your original data
 
I don't receive it from a device btw, I fabricate it in a unit test the same was as I encode it
so the encoding part is faulty?
 
No, you don't have enough bits
-3000 is 11111111111111111111010001001000
You need 13 bits at a minimum
Eleven will drop the first 10
 
ok
just a random question. How about -1000
 
9:06 AM
So even if you convert my output back to two's complement, you'll get -952
Nope, you'll need 12 bits for 1000
10000011000 is the bare bit data, and you will need one more bit for sign
How long are these devices expected to remain functional?
 
you're giving me all BLE headache
 
You could very possibly trim bits from the time stamp
The first few bits take decades to change
You can just tack them on client side later
 
these 21 bits contain "seconds relative to a 'start'" and can represent up to 24 days
 
Hmm
Okay, can't trim that then
 
start is stored elsewhere
 
9:11 AM
Can you add another byte of data?
 
no I have to follow a spec
 
With 11 bits you can at most cover 1024 temperatures
Unless you want to get fancy
And come up with a hacky float point like representation
 
it is either a positive value 0 to 1023 or a negative value of -1000
 
1 sign bit + 2^10 values
So -1024 to 1023
 
so that checks out
 
9:13 AM
Hmm, I must have calculated my -1000 bits wrong
 
I don't know
 
Ah, no, I didn't
I just read it wrong
 
I changed my -3000 constant to -1000 and suddenly test passes
 
-1000 is too small to need the trailing one, that was the sign bit
Yeah, it should, your -3000 would never decode correctly
 
help, I'm a retard
 
9:15 AM
Except, in -1000, your sign bit is magically preserved
 
during encode?
 
Well, it actually won't impact you as long as you stick to -1024 to 1023
The sign bit will always be preserved
 
I use this
/** Shifts this value right by the [bitCount] number of bits, filling the leftmost bits with copies of the sign bit. */
public infix fun shr(bitCount: Int): Int
 
But yes, if you exceed that, the sign bit may change and spit out the wrong result
Like with -3000
 
that makes a lot of sense
 
9:16 AM
Yeah, that will do
These are your binary constraints:
>
111111111111111111111 10000011000
000000000000000000000 01111101000
(space mine)
Notice how the left hand side is static up to the 11th bit (first one after the space)
As long as you're in this range, the left shift won't lose data
 
we are implementing identical en/decoding algos on android and iOS because we will interchange data but historically we used -3000 for invalid temp and they used -1000. Guess who wrote the spec for this :D
 
But in -3000 (111111111111111111110 10001001000), you lose data, because two bits are lost
 
yes it makes sense. Thanks for wasting your time to help me
 
No problem, glad it works!
Back to contract writing for me
 
nice
 
9:30 AM
Hmm, I hope the Thinkpad bluetooth works on ubuntu
I don't wanna give up my QC35
So nice for shutting out the party across the road
 
9:43 AM
stackoverflow.com/a/51521261/1843331 103 upvotes for saying "this guy's answer is correct"
 
unholy shit
 
faith in humanity lost
 
don't be grumpy timmy
thats how you earn reps nowadays
 
BAD NEWS : the other offer was accepted by the bank
 
9:46 AM
kill them... slowly
 
:(
 
GOOD NEWS: the sales woman found got me one that was at 611€ for 380€
 
Even better, start a bank and tank the economy, forcing the bank and the other renter to shut down
 
i'm visiting it this afternoon
^ the new, new flat.
 
Electrum frontend client such as? — Gagan 1 min ago
 
9:51 AM
xD
 
Slightly different electrum
@TimCastelijns I'm curious, what possible device could you have that can reach temps of -3000?
That seems literally impossible
 
opinions?
 
I ask, because if it is temp you're dealing with, you can just skip the whole signed/unsigned nonsense and assume your 11 bits count up from 0k
You will get a larger range of usable temperatures
 
hmm the bedroom seems small eric
 
9:55 AM
And depending on the max temp it'll hit, you could even have more than 24 days on the clock
 
wow BIG!
 
Looks good to me, Eric
Not all of us can afford palaces, CF
 
What is the T at top?
 
T = terrace
just a balcony really
 
terrace
 
9:55 AM
by the size
 
oh. thanks.
 
and somehow they miss-wrote B2
but there's two bathrooms in there
 
How much would that be? average,
 
by the price, above average.
but i'm sad by the loss of my loved other flat
it really had a fancy kitchen
</3
let's see how this one goes.
 
i didnt like the bedroom bathroom placement
rest is all good
 
9:57 AM
this one is smaller?
 
same size as per map
the other one was more rectangular
this one is slightly odd shaped
i'll bring a size meter
because the rooms look small
 
yeah
 
the main one looks fine tho
 

« first day (2841 days earlier)      last day (2122 days later) »