I 'think' I'm coming to grips with using 'Terminals' !! - Page 1
Forum section: electronics / general

author: GlennSprigg
author_rank: Super Contributor
timestamp: April 18, 2021, 01:17:43 pm
content: (As my Profile says... Retired, old school, re-learning.. haha..)Some of my previous posts have been about my (now successful) utilization of various VirtualBox 'Guests', like Mac-OS, Ubuntu-Mate, and Android-X86,mainly for the simple purpose of self education, and a bit of fun!! However, I can't help myself from delving under the hood!! As a Windows user, I'venever had to delve into 'Terminal' mode as much as I am now, especially with regards to Ubuntu/Linux. (Yes, I know you don't 'have' to as a basic user).I WON'T get into the argument (truth) how they all started from some form of Unix/Linux anyway, but I am now slowly understanding & playing with allthe different under-hood File-Systems for all those above, which is SO different from Windows!! It took me a while to realize that there is NO simple Drive-Cor 'D' or what ever, as all such 'devices' are merely specific files/folders. After many hours of videos explaining the various OS 'file-structures', and how to findmy way around them, it's all starting to make sense!I've come to one conclusion though, that I can't see the point(?) of setting up an Android-X86 Guest,when BlueStacks does it all, SO much better/faster, & with virtually full hardware compatibility ??Anyway... Re: BlueStacks, it doesn't take a Rocket-Scientist to realize/find 'BlueStacks Tweaker' !! that can remove/block all the Ads, 'ROOT' it, and amongstother things include a powerful simplistic file viewer, that works under the hood. Although now playing with Terminals has greatly increased the Fun, whenin 'SuperUser' modes, at folder/file level. I've also done some software 'cracking' just for fun!, delving deep into Mac-OS & Android, and editing certain files.It's been a fun ride so far, and I keep on learning!

author: MrMobodies
author_rank: Super Contributor
timestamp: April 18, 2021, 07:30:13 pm
content: I remembered using Bluestacks some years ago to experiment a Wifi Olympus dictatphone recorder DM-901. What I did I joined Netgear Wdnap210 to it in bridge mode, connected it to a pfsense firewall and setup some static routes using the same network range as the dictaphone wireless and "App" found it as it seems looking just for that IP address. It does things like, record, stop, and I think it can download recordings to the whatever device it was on. I also wanted to test out some SKY RC batteri charges but couldn't find a way of getting to work with bluetooth.

author: newbrain
author_rank: Super Contributor
timestamp: April 18, 2021, 08:49:34 pm
content: Kudos!You enthusiasm is refreshing!Always nice to learn and tinker.And since you are coming to terms with terminals, I would advise to invest some time in getting to know Windows.There's now a decentterminal program, much nicer than the usual console.Also on github, if you feel like it.But the container is not much without good content: enter PowerShell.PowerShell is a very powerful scripting language, with a regular syntax (Verb-Object), object-oriented and on Windows - it's also available on Linux and Mac - a deep integration with the system.Good string handling, arithmetic etc.: it vaguely reminds me of DCL (VMS scripting language) - because, you know, not all OSs come from a Unix root (truth!)...but I digress, not the discussion I want to have now!It tends to be verbose, though, but all cmdlets have auto complete and most shorter default aliases.While Windows 10 comes with PS 5 by default,PowerShell 7is available.The set of available commands covers 99% of what you can do with the GUI, plus tons of other stuff.As an example of its versatility, I use a PS script to send WoL UDP packets to machines on my network, and it uses no external programs.As a second example, at work I used it to drive a simulation from a table of input parameters, and table out the results.About Windows and the disks: "C:" is just a name for a volume with its special path, and devices also have their own:Code:PS C:\WINDOWS\system32> Get-Volume -DriveLetter C | Select-Object -Property PathPath----\\?\Volume{4fffff70-6001-01d5-b887-efa700b0ea00}\PS C:\WINDOWS\system32> Get-Disk -Number 2 | Select-Object -Property PathPath----\\?\scsi#disk&ven_samsung&prod_ssd_840_evo_250g#5&2c4dbacb&0&010000#{53f56307-b6bf-11d0-94f2-00a0c91efb8b}The upper OS layers rely on that alias for too many things (and backward compatibility), but it is possible (and has been for ages) to mount other disks under folders instead of assigning them letters. For example, I mounted an SD card under C:/mount (and yes, PS - and in general Windows calls - accepts forward slashes, cmd does not though):Code:PS C:\> Get-WmiObject Win32_Volume | Where-Object -Property Name -Like "*mount*" | Format-Table -Property Name,Label,FileSystemName Label FileSystem---- ----- ----------C:\mount\ NIKON D7100 exFAT

author: GlennSprigg
author_rank: Super Contributor
timestamp: April 19, 2021, 07:22:23 am
content: Thanksnewbrain. I'll delve into that a bit more!P.S. 何でもは知らないわよ。知ってることだけ。Maybe so, but I think you know a lot !!

author: fordem
author_rank: Regular Contributor
timestamp: April 21, 2021, 01:14:04 pm
content: My introduction to "terminals" predates both Microsoft & the IBM PC - I've worked with both the "teletype" and it's successor the "glass teletype" attached to a minicomputer via a serial port. QModem was my terminal emulator back in the DOS days, followed by HyperTerminal Private Edition after I moved to Windows, Putty is now my goto.

author: Halcyon
author_rank: Unknown
timestamp: April 21, 2021, 07:37:53 pm
content: I found that my years of working in MS-DOS prompt and just understanding syntax in general helped greatly when it came to learning Linux commands. Now I find myself typing ls in Windows instead of dir.

author: newbrain
author_rank: Super Contributor
timestamp: April 21, 2021, 08:19:38 pm
content: Quote from: Halcyon on April 21, 2021, 07:37:53 pmWhich, (un)surprisingly works quite well - as long as you don't use any options:Code:~\Git\RT1020\scripts [NewUI ≡ +0 ~2 -0 !]> lsDirectory: C:\Users\feder\Git\RT1020\scriptsMode LastWriteTime Length Name---- ------------- ------ -----a--- 2021-04-19 19:22 1098 clang_arm_toolchain.cmake-a--- 2021-04-12 13:15 1083 compiler-rtPScmd.txt-a--- 2021-04-21 01:00 529 create_version.cmake-a--- 2021-04-12 13:15 1641 mem_sizes.cmake-a--- 2021-04-12 23:59 1096 options.cmake-a--- 2021-04-12 13:15 482 RT1020_library.ld-a--- 2021-04-12 13:15 1499 RT1020_memory.ld-a--- 2021-04-12 13:15 6832 RT1020.ld-a--- 2021-04-12 13:15 730 system_deps.cmake-a--- 2021-04-12 13:15 77 version.h.in~\Git\RT1020\scripts [NewUI ≡ +0 ~2 -0 !]> alias lsCommandType Name Version Source----------- ---- ------- ------Alias ls -> Get-ChildItemas it's part of the standard alias in PowerShell

author: Halcyon
author_rank: Unknown
timestamp: April 22, 2021, 09:07:35 am
content: Quote from: newbrain on April 21, 2021, 08:19:38 pmIn PowerShell yes, but not the standard Command prompt if I recall correctly?

author: newbrain
author_rank: Super Contributor
timestamp: April 22, 2021, 01:27:04 pm
content: Quote from: Halcyon on April 22, 2021, 09:07:35 amNo, it's not, one can use DOSKEY to define one, though.The cmd language has been quite extended from the old days, and now lets you write decent scripts.Still, PowerShell is on another level - I've notwillinglyused cmd in ages.

author: GlennSprigg
author_rank: Super Contributor
timestamp: April 24, 2021, 11:57:16 am
content: Quote from: fordem on April 21, 2021, 01:14:04 pmI remember back in the days with my 'Security Systems' work, (I dunno... 20-30 years ago!), virtually every 'Smart' (then!) security/access-controlpanel//equip had an 'RS232' socket on the side. As did those ancient 'laptops' back then!!! One would plug it in, and select the ubiquitous Baudrate, Parity, stop bits etc, and 'talk' to them via a Terminal program on the 'Laptop'. A simple DOS style interface for programming & data acquisition.It SEEMED soHigh-Techback then, and customers were amazed !!!

author: rsjsouza
author_rank: Super Contributor
timestamp: April 24, 2021, 12:37:02 pm
content: Glenn, the terminal is a beautiful thing; I have been using it for quite some time and the mechanical memory you end up getting is very powerful. Welcome to the "new" world.