|
The cable wont arrive until Wednesday (UK) I'll let you know if it works
We can’t stop here, this is bat country - Hunter S Thompson RIP
|
|
|
|
|
In any case, check again exactly. You will not believe it, but I had a nightmare that night in which your devices went down because I was wrong. I was about to get up at four o'clock in the morning to check everything again
It does not solve my Problem, but it answers my question
modified 19-Jan-21 21:04pm.
|
|
|
|
|
Just to update you, the cable you suggested duly arrived , but when I fitted it the drives and the fan span up and down ( like revvivg an engine on a starting grid ) constantly when powered from the hat. If I power it from the USBC on the board all is good ( although I suspect it's not getting enough power ) any ideas ?
We can’t stop here, this is bat country - Hunter S Thompson RIP
|
|
|
|
|
Is the power output of the SBC ok? Sorry, no other idea.
It does not solve my Problem, but it answers my question
modified 19-Jan-21 21:04pm.
|
|
|
|
|
It must be because when I power the SBC via USB and connect the Molex to the hat and drive bay all is fine - weird
We can’t stop here, this is bat country - Hunter S Thompson RIP
|
|
|
|
|
pkfox wrote: I need a female to female I've got just the site for that!
pkfox wrote: Molex power cable for my NanoPi M4 project Oh uh... Nevermind
|
|
|
|
|
Is the UK still in the EU?
|
|
|
|
|
public class SomeLocationData
{
public SomeLocationData(Long someAreaId, String longitude, String latitude)
{
if ((someAreaId == null) == (longitude == null || latitude == null))
{
throw new IllegalArgumentException("Either someAreaId or coordinates must be specified.");
}
THAT CHECK.
|
|
|
|
|
That's the most horrible thing I've seen today.
Regards,
Rob Philpott.
|
|
|
|
|
TBF it's an IDE's "autofix". I've written a condition:
isValid = (someAreaId != null) ^ (longitude != null && latitude != null);
if (!isValid) { ...
Which literally translates to "either someAreaId is not null or both coordinates are not null". This is a required business logic and it doesn't seem to be a way around it.
And then I got a "simplify boolean" and "inline variable" quickfixes. If you pass the initial "WTF" feeling, then it starts to make sense.
|
|
|
|
|
Looks like a buggy check... what if all 3 are specified?
That's will throw the error, that's what!
|
|
|
|
|
I think that's what it's supposed to do.
Either one or the other needs to have a value, not both and not neither
|
|
|
|
|
well perhaps.. but then the error message is misleading!
|
|
|
|
|
How is
Either someAreaId or coordinates must be specified.
misleading, it doesn't say AND?
|
|
|
|
|
Mmm.. maybe the nuance of English are lost on me.. not being a native...
This message doesn't seem to imply to me that it is wrong to have both condition true...
|
|
|
|
|
It's the very definition of "either... or..." (a.k.a. XOR)
Actually, I don't think the code is that bad.
I think a lot more programmers can read that than an XOR, which is far from common in C#.
|
|
|
|
|
It does not solve my Problem, but it answers my question
modified 19-Jan-21 21:04pm.
|
|
|
|
|
Sander Rossel wrote: Actually, I don't think the code is that bad.
I think a lot more programmers can read that than an XOR, which is far from common in C#.
OK so I don't need to duck & cover if I say that I have left it as it was?
|
|
|
|
|
|
|
Ouch!. My bad. Thanks
modified 23-Jun-22 21:01pm.
|
|
|
|
|
It's old school rock!
I remembered how to MessageBox (in Client) some texts on ASP.NET...
protected void ShowMessage(string message)
{
string msg = "alert('" + message + "');";
base.ClientScript.RegisterStartupScript(base.GetType(), "jsShowMessage", msg, true);
}
Yeah!
|
|
|
|
|
Has anyone played with Outerrnet/Othernet? What were your experiences with it?
CQ de W5ALT
Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
Out of this world!
[EDIT] I just realised it's a real thing!
Were you asking about it?
|
|
|
|
|
looks like just another version of NAS over wifi
=====================================================
The grass is always greener on the other side of the fence
|
|
|
|